Skip to content

Commit d313bf2

Browse files
committed
Convert A5-0-4 to use the new dataflow library
1 parent 30114c5 commit d313bf2

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

cpp/autosar/src/rules/A5-0-4/PointerArithmeticUsedWithPointersToNonFinalClasses.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import cpp
1818
import codingstandards.cpp.autosar
1919
import codingstandards.cpp.Type
20-
import semmle.code.cpp.dataflow.DataFlow
20+
import semmle.code.cpp.dataflow.new.DataFlow
2121
import NonFinalClassToPointerArithmeticExprFlow::PathGraph
2222

2323
class ArrayAccessOrPointerArith extends Expr {

cpp/autosar/test/rules/A5-0-4/PointerArithmeticUsedWithPointersToNonFinalClasses.expected

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
1-
WARNING: module 'DataFlow' has been deprecated and may be removed in future (PointerArithmeticUsedWithPointersToNonFinalClasses.ql:45,62-70)
2-
WARNING: module 'DataFlow' has been deprecated and may be removed in future (PointerArithmeticUsedWithPointersToNonFinalClasses.ql:46,22-30)
3-
WARNING: module 'DataFlow' has been deprecated and may be removed in future (PointerArithmeticUsedWithPointersToNonFinalClasses.ql:55,20-28)
4-
WARNING: module 'DataFlow' has been deprecated and may be removed in future (PointerArithmeticUsedWithPointersToNonFinalClasses.ql:61,3-11)
51
edges
62
| test.cpp:10:18:10:20 | foo | test.cpp:11:23:11:25 | foo | provenance | |
73
| test.cpp:10:18:10:20 | foo | test.cpp:11:50:11:52 | foo | provenance | |
84
| test.cpp:22:18:22:20 | foo | test.cpp:24:18:24:20 | foo | provenance | |
5+
| test.cpp:35:11:35:17 | new | test.cpp:35:11:35:17 | new | provenance | |
96
| test.cpp:35:11:35:17 | new | test.cpp:38:6:38:7 | l1 | provenance | |
107
| test.cpp:35:11:35:17 | new | test.cpp:39:6:39:7 | l1 | provenance | |
8+
| test.cpp:37:11:37:13 | & ... | test.cpp:37:11:37:13 | & ... | provenance | |
119
| test.cpp:37:11:37:13 | & ... | test.cpp:40:6:40:7 | l3 | provenance | |
1210
| test.cpp:37:11:37:13 | & ... | test.cpp:41:6:41:7 | l3 | provenance | |
1311
| test.cpp:38:6:38:7 | l1 | test.cpp:10:18:10:20 | foo | provenance | |
@@ -21,6 +19,8 @@ nodes
2119
| test.cpp:22:18:22:20 | foo | semmle.label | foo |
2220
| test.cpp:24:18:24:20 | foo | semmle.label | foo |
2321
| test.cpp:35:11:35:17 | new | semmle.label | new |
22+
| test.cpp:35:11:35:17 | new | semmle.label | new |
23+
| test.cpp:37:11:37:13 | & ... | semmle.label | & ... |
2424
| test.cpp:37:11:37:13 | & ... | semmle.label | & ... |
2525
| test.cpp:38:6:38:7 | l1 | semmle.label | l1 |
2626
| test.cpp:39:6:39:7 | l1 | semmle.label | l1 |

0 commit comments

Comments
 (0)