Skip to content

Commit 4231bb1

Browse files
committed
Python: Show how pointsTo handles 0+0 == 0 (1/2)
1 parent 6b5b28a commit 4231bb1

2 files changed

Lines changed: 11 additions & 8 deletions

File tree

python/ql/test/library-tests/PointsTo/comparisons/PointsTo.expected

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,15 @@
1212
| 21 | file://:0:0:0:0 | bool True |
1313
| 22 | file://:0:0:0:0 | bool False |
1414
| 22 | file://:0:0:0:0 | bool True |
15-
| 25 | file://:0:0:0:0 | bool False |
16-
| 26 | file://:0:0:0:0 | bool False |
17-
| 27 | file://:0:0:0:0 | bool True |
18-
| 28 | file://:0:0:0:0 | bool True |
15+
| 28 | file://:0:0:0:0 | bool False |
1916
| 29 | file://:0:0:0:0 | bool False |
2017
| 30 | file://:0:0:0:0 | bool True |
21-
| 33 | file://:0:0:0:0 | bool False |
22-
| 34 | file://:0:0:0:0 | bool True |
23-
| 35 | file://:0:0:0:0 | bool False |
18+
| 31 | file://:0:0:0:0 | bool True |
19+
| 32 | file://:0:0:0:0 | bool False |
20+
| 33 | file://:0:0:0:0 | bool True |
2421
| 36 | file://:0:0:0:0 | bool False |
2522
| 37 | file://:0:0:0:0 | bool True |
26-
| 38 | file://:0:0:0:0 | bool True |
23+
| 38 | file://:0:0:0:0 | bool False |
24+
| 39 | file://:0:0:0:0 | bool False |
25+
| 40 | file://:0:0:0:0 | bool True |
26+
| 41 | file://:0:0:0:0 | bool True |

python/ql/test/library-tests/PointsTo/comparisons/test.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@
2121
len(unknown()) == len(unknown())
2222
len(unknown()) < len(unknown())
2323

24+
# 0+0 == 0
25+
# 0+1 == 0
26+
2427
#All ops
2528
2 > 3
2629
2 == 3

0 commit comments

Comments
 (0)