@@ -12,6 +12,16 @@ abstract class NotDistinctIdentifierSharedQuery extends Query { }
1212
1313Query getQuery ( ) { result instanceof NotDistinctIdentifierSharedQuery }
1414
15+ bindingset [ d, d2]
16+ pragma [ inline_late]
17+ private predicate after ( ExternalIdentifiers d , ExternalIdentifiers d2 ) {
18+ exists ( int dStartLine , int d2StartLine |
19+ d .getLocation ( ) .hasLocationInfo ( _, dStartLine , _, _, _) and
20+ d2 .getLocation ( ) .hasLocationInfo ( _, d2StartLine , _, _, _) and
21+ dStartLine >= d2StartLine
22+ )
23+ }
24+
1525query predicate problems (
1626 ExternalIdentifiers d , string message , ExternalIdentifiers d2 , string nameplaceholder
1727) {
@@ -20,10 +30,10 @@ query predicate problems(
2030 d .getName ( ) .length ( ) >= 31 and
2131 d2 .getName ( ) .length ( ) >= 31 and
2232 not d = d2 and
23- d .getLocation ( ) .getStartLine ( ) >= d2 .getLocation ( ) .getStartLine ( ) and
2433 d .getSignificantName ( ) = d2 .getSignificantName ( ) and
2534 not d .getName ( ) = d2 .getName ( ) and
2635 nameplaceholder = d2 .getName ( ) and
36+ after ( d , d2 ) and
2737 message =
2838 "External identifer " + d .getName ( ) +
2939 " is nondistinct in characters at or over 31 limit, compared to $@"
0 commit comments