boolean (@NotNull MergeableUsage other) { if (!(other instanceof UsageInfo2UsageAdapter u2)) return false; assert u2 != this; if (myLineNumber != u2.myLineNumber || !Comparing.equal(getFile(), u2.getFile())) return false; UsageInfo[] merged = ArrayUtil.mergeArrays(getMergedInfos(), u2.getMergedInfos()); myMergedUsageInfos = merged.length == 1 ? merged[0] : merged; Arrays.sort(getMergedInfos(), BY_NAVIGATION_OFFSET); // Invalidate cached presentation, so it'll be updated later // Do not reset it to still have something to present myModificationStamp = Long.MIN_VALUE; return true; }