- if (inNodeInferLoc.getTuple().startsWith(curPrefix)
- && inNodeInferLoc.getSize() == (curPrefix.size() + 1)) {
- String higher = inNodeInferLoc.get(inNodeInferLoc.getSize() - 1).getLocIdentifier();
- if (!higher.equals(newlyInsertedLocName)) {
- System.out.println("add localInNodeSet relation:");
- addRelationHigherToLower(lattice, locInfo, higher, newlyInsertedLocName);
- }
- } else {
- throw new Error("Failed to generate a composite location.");
- }
+ addRelation(methodLattice, methodInfo, inNodeInferLoc, inferLocation);