mirror of
https://github.com/github/codeql.git
synced 2026-04-30 19:26:02 +02:00
CPP: Add a test of ErroneousType.
This commit is contained in:
1
cpp/ql/test/library-tests/types/error/exprs.expected
Normal file
1
cpp/ql/test/library-tests/types/error/exprs.expected
Normal file
@@ -0,0 +1 @@
|
||||
| file://:0:0:0:0 | <error expr> | file://:0:0:0:0 | error |
|
||||
5
cpp/ql/test/library-tests/types/error/exprs.ql
Normal file
5
cpp/ql/test/library-tests/types/error/exprs.ql
Normal file
@@ -0,0 +1,5 @@
|
||||
import cpp
|
||||
|
||||
from Expr e, Type t
|
||||
where t = e.getType()
|
||||
select e, t
|
||||
3
cpp/ql/test/library-tests/types/error/test.cpp
Normal file
3
cpp/ql/test/library-tests/types/error/test.cpp
Normal file
@@ -0,0 +1,3 @@
|
||||
// semmle-extractor-options: --expect_errors
|
||||
|
||||
int &intref = 0; // ErrorExpr with ErroneousType
|
||||
Reference in New Issue
Block a user