Skip to content

Commit 53c5b8f

Browse files
committed
CPP: Prevent forced bad join order.
1 parent bc6ce32 commit 53c5b8f

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

cpp/ql/lib/semmle/code/cpp/dataflow/ExternalFlow.qll

+5-4
Original file line numberDiff line numberDiff line change
@@ -869,12 +869,13 @@ private predicate elementSpecMatchesSignature(
869869
bindingset[nameWithoutArgs]
870870
pragma[inline_late]
871871
private Class getClassAndNameImpl(Function method, string nameWithoutArgs) {
872-
exists(string memberName | result = method.getClassAndName(memberName) |
872+
exists(string memberName |
873+
result = method.getClassAndName(memberName) and
873874
nameWithoutArgs = "operator " + method.(ConversionOperator).getDestType()
874-
or
875-
not method instanceof ConversionOperator and
876-
memberName = nameWithoutArgs
877875
)
876+
or
877+
result = method.getClassAndName(nameWithoutArgs) and
878+
not method instanceof ConversionOperator
878879
}
879880

880881
/**

0 commit comments

Comments
 (0)