private void checkInvariants() {
    if (!LOG.isDebugEnabled() && !ApplicationManager.getApplication().isEAP()) return;
    for (Int2IntMap.Entry entry : myIdToEqClassesIndices.int2IntEntrySet()) {
      EqClassImpl eqClass = myEqClasses.get(entry.getIntValue());
      if (eqClass == null || !eqClass.contains(entry.getIntKey())) {
        LOG.error("Invariant violated: null-class for id=" + myFactory.getValue(entry.getIntKey()));
      }
    }
    Int2ObjectMap<BitSet> graph = new Int2ObjectOpenHashMap<>();
    for (DistinctPairSet.DistinctPair pair : myDistinctClasses) {
      if (pair.isOrdered()) {
        BitSet set = graph.get(pair.getFirstIndex());
        if (set == null) {
          set = new BitSet();
          graph.put(pair.getFirstIndex(), set);
        }
        set.set(pair.getSecondIndex());
      }
      pair.check();
    }
    BitSet visited = new BitSet();
    BitSet stack = new BitSet();
    for (int v : graph.keySet()) {
      if (isCycle(v, graph, visited, stack)) {
        throw new IllegalStateException("Cycle in distinct pairs involving " + myEqClasses.get(v));
      }
    }
  }
private void checkInvariants()