mirror of
https://github.com/github/codeql.git
synced 2026-03-31 12:48:17 +02:00
C++: NSDMI fixes
* Do not generate IR for field initializers from uninstantiated templates. * Add forgotten case to `TranslatedDeclarationEntry`
This commit is contained in:
@@ -47,6 +47,7 @@ module Raw {
|
||||
not var.isFromUninstantiatedTemplate(_) and
|
||||
var instanceof StaticInitializedStaticLocalVariable
|
||||
or
|
||||
not var.isFromUninstantiatedTemplate(_) and
|
||||
var instanceof Field
|
||||
) and
|
||||
var.hasInitializer() and
|
||||
|
||||
@@ -34,6 +34,8 @@ abstract class TranslatedDeclarationEntry extends TranslatedElement, TTranslated
|
||||
or
|
||||
result = entry.getDeclaration().(GlobalOrNamespaceVariable)
|
||||
or
|
||||
result = entry.getDeclaration().(Field)
|
||||
or
|
||||
not entry.getDeclaration() instanceof StaticInitializedStaticLocalVariable and
|
||||
not entry.getDeclaration() instanceof GlobalOrNamespaceVariable and
|
||||
not entry.getDeclaration() instanceof Field and
|
||||
|
||||
Reference in New Issue
Block a user