mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
C/C++ overlay: Add overlay support for discarding namespaces
This commit is contained in:
@@ -26,6 +26,8 @@ private string getSingleLocationFilePath(@element e) {
|
|||||||
fun_decls(e, _, _, _, loc)
|
fun_decls(e, _, _, _, loc)
|
||||||
or
|
or
|
||||||
type_decls(e, _, loc)
|
type_decls(e, _, loc)
|
||||||
|
or
|
||||||
|
namespace_decls(e, _, loc, _)
|
||||||
|
|
|
|
||||||
result = getLocationFilePath(loc)
|
result = getLocationFilePath(loc)
|
||||||
)
|
)
|
||||||
@@ -42,6 +44,8 @@ private string getMultiLocationFilePath(@element e) {
|
|||||||
exists(@fun_decl fd | fun_decls(fd, e, _, _, loc))
|
exists(@fun_decl fd | fun_decls(fd, e, _, _, loc))
|
||||||
or
|
or
|
||||||
exists(@type_decl td | type_decls(td, e, loc))
|
exists(@type_decl td | type_decls(td, e, loc))
|
||||||
|
or
|
||||||
|
exists(@namespace_decl nd | namespace_decls(nd, e, loc, _))
|
||||||
|
|
|
|
||||||
result = getLocationFilePath(loc)
|
result = getLocationFilePath(loc)
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user