File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
src/codingstandards/cpp/rules/throwingoperatornewreturnsnull
test/rules/throwingoperatornewreturnsnull Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 44 */
55
66import cpp
7- import semmle.code.cpp.dataflow.DataFlow
7+ import semmle.code.cpp.dataflow.new. DataFlow
88import codingstandards.cpp.allocations.CustomOperatorNewDelete
99import codingstandards.cpp.exceptions.ExceptionSpecifications
1010import codingstandards.cpp.Customizations
Original file line number Diff line number Diff line change @@ -3,10 +3,16 @@ problems
33| test.cpp:12:5:12:19 | return ... | test.cpp:12:12:12:18 | 0 | test.cpp:12:12:12:18 | 0 | operator new(size_t) may return null instead of throwing a std::bad_alloc exception. |
44| test.cpp:14:5:14:33 | return ... | test.cpp:4:10:4:23 | call to operator new | test.cpp:14:12:14:26 | call to can_return_null | operator new(size_t) may return null instead of throwing a std::bad_alloc exception. |
55edges
6- | test.cpp:4:10:4:23 | call to operator new | test.cpp:14:12:14:26 | call to can_return_null | provenance | |
6+ | test.cpp:3:7:3:21 | *can_return_null | test.cpp:14:12:14:26 | call to can_return_null | provenance | |
7+ | test.cpp:4:10:4:23 | call to operator new | test.cpp:3:7:3:21 | *can_return_null | provenance | |
8+ | test.cpp:4:10:4:23 | call to operator new | test.cpp:4:10:4:23 | call to operator new | provenance | |
9+ | test.cpp:8:23:8:23 | 0 | test.cpp:8:23:8:23 | 0 | provenance | |
710| test.cpp:8:23:8:23 | 0 | test.cpp:10:12:10:24 | localVariable | provenance | |
811nodes
12+ | test.cpp:3:7:3:21 | *can_return_null | semmle.label | *can_return_null |
913| test.cpp:4:10:4:23 | call to operator new | semmle.label | call to operator new |
14+ | test.cpp:4:10:4:23 | call to operator new | semmle.label | call to operator new |
15+ | test.cpp:8:23:8:23 | 0 | semmle.label | 0 |
1016| test.cpp:8:23:8:23 | 0 | semmle.label | 0 |
1117| test.cpp:10:12:10:24 | localVariable | semmle.label | localVariable |
1218| test.cpp:12:12:12:18 | 0 | semmle.label | 0 |
You can’t perform that action at this time.
0 commit comments