Skip to content

Commit 92fdedf

Browse files
Update cpp/misra/src/rules/RULE-28-6-4/PotentiallyErroneousContainerUsage.ql
Co-authored-by: Mauro Baluda <mbaluda@github.com>
1 parent 7912c40 commit 92fdedf

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

cpp/misra/src/rules/RULE-28-6-4/PotentiallyErroneousContainerUsage.ql

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,7 @@ import codingstandards.cpp.misra
1919
import codingstandards.cpp.Iterators
2020

2121
predicate isRemoveOrUniqueCall(FunctionCall fc) {
22-
exists(string name | name = fc.getTarget().getName() |
23-
name = "remove" or
24-
name = "remove_if" or
25-
name = "unique"
26-
) and
27-
fc.getTarget().hasQualifiedName("std", _) and
22+
fc.getTarget().hasQualifiedName("std", ["remove", "remove_if", "unique"]) and
2823
fc.getAnArgument().getUnderlyingType() instanceof IteratorType
2924
}
3025

0 commit comments

Comments
 (0)