We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0584191 commit 518b45bCopy full SHA for 518b45b
1 file changed
cpp/ql/test/query-tests/Best Practices/Unused Entities/UnusedStaticFunctions/unused_static_functions.cpp
@@ -33,3 +33,16 @@ static void f6(void);
33
static void f5(void) { f6(); }
34
static void f6(void) { f5(); }
35
36
+// f7 and f8 are reachable from `function_caller`
37
+static int f7() { return 1; } // GOOD
38
+static void f8() { } // GOOD
39
+
40
+void function_caller()
41
+{
42
+ auto my_lambda = []() {
43
+ return f7();
44
+ }();
45
46
+ f8();
47
+}
48
0 commit comments