Incorrect subSMG level calculation when merging
Incorrect calculation of the subSMG level when merging a list containing a nested list of level 1 with some other object. For example, we merge SLL(id=42, level=0) containing nested SLL(id=43, level=1) with REGION(level=0). To perform the merge, insertLeftListAndJoin algorithm inserts SLL after REGION and merges it with SLL(id=43, level=1). The level of new nested SLL calculated in SMGJoinValues.java:1429 (listLevel = pList.getLevel() + pLevelDiff) which in our example is equal to 0 (pList.getLevel() = 1, pLevelDiff = -1). It looks like there is an incorrect calculation pLevelDiff in SMGJoinValues.java:1042 (pPrevDestLevel = 0, pTarget.getLevel() = 1). After merging we get SLL(level=0), so we lose information about its nesting level.
The test program in which this bug appears was run with the options: -setprop cpa.smg.seqLengthEntailmentThreshold=3 -setprop cpa.smg.seqLengthEqualityThreshold=3 -setprop cpa.smg.seqLengthIncomparableThreshold=3 sll_lose_level.c