diff --git a/cpp/ql/lib/semmle/code/cpp/Namespace.qll b/cpp/ql/lib/semmle/code/cpp/Namespace.qll index 129e1449c32..065e28c8429 100644 --- a/cpp/ql/lib/semmle/code/cpp/Namespace.qll +++ b/cpp/ql/lib/semmle/code/cpp/Namespace.qll @@ -230,8 +230,12 @@ class GlobalNamespace extends Namespace { } /** - * The C++ `std::` namespace. + * The C++ `std::` namespace and its inline namespaces. */ class StdNamespace extends Namespace { - StdNamespace() { this.hasName("std") and this.getParentNamespace() instanceof GlobalNamespace } + StdNamespace() { + this.hasName("std") and this.getParentNamespace() instanceof GlobalNamespace + or + this.isInline() and this.getParentNamespace() instanceof StdNamespace + } }