mirror of
https://github.com/github/codeql.git
synced 2025-12-18 01:33:15 +01:00
Merge pull request #303 from jbj/UnsignedGEZero-templates
C++: Suppress UnsignedGEZero.ql in template instantiations
This commit is contained in:
@@ -50,5 +50,6 @@ predicate unsignedGEZero(UnsignedGEZero ugez, string msg) {
|
||||
ugez.getLocation().getStartLine() = mi.getLocation().getStartLine() and
|
||||
ugez.getLocation().getStartColumn() = mi.getLocation().getStartColumn()
|
||||
) and
|
||||
not ugez.isFromTemplateInstantiation(_) and
|
||||
msg = "Pointless comparison of unsigned value to zero."
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user