boolean (ControlFlowGraph graph) { Map<BasicBlock, Set<BasicBlock>> mapRanges = new HashMap<>(); for (ExceptionRangeCFG range : graph.getExceptions()) { mapRanges.computeIfAbsent(range.getHandler(), k -> new HashSet<>()).addAll(range.getProtectedRange()); } for (Entry<BasicBlock, Set<BasicBlock>> ent : mapRanges.entrySet()) { Set<BasicBlock> setEntries = new HashSet<>(); for (BasicBlock block : ent.getValue()) { Set<BasicBlock> setTemp = new HashSet<>(block.getPredecessors()); setTemp.removeAll(ent.getValue()); if (!setTemp.isEmpty()) { setEntries.add(block); } } if (!setEntries.isEmpty()) { if (setEntries.size() > 1 /*|| ent.getValue().contains(first)*/) { return true; } } } return false; }