@@ -295,10 +295,13 @@ newtype TCodeIndentifierDeviation =
295
295
} or
296
296
TMultiLineDeviation (
297
297
DeviationRecord record , DeviationBegin beginComment , DeviationEnd endComment , string filepath ,
298
- int suppressedStartLine , int suppressedEndLine , int suppressedEndColumn
298
+ int suppressedStartLine , int suppressedStartColumn , int suppressedEndLine ,
299
+ int suppressedEndColumn
299
300
) {
300
301
isDeviationRangePaired ( record , beginComment , endComment ) and
301
- beginComment .getLocation ( ) .hasLocationInfo ( filepath , suppressedStartLine , _, _, _) and
302
+ beginComment
303
+ .getLocation ( )
304
+ .hasLocationInfo ( filepath , suppressedStartLine , suppressedStartColumn , _, _) and
302
305
endComment .getLocation ( ) .hasLocationInfo ( filepath , _, _, suppressedEndLine , suppressedEndColumn )
303
306
} or
304
307
TCodeIdentifierDeviation ( DeviationRecord record , DeviationAttribute attribute ) {
@@ -310,7 +313,7 @@ class CodeIdentifierDeviation extends TCodeIndentifierDeviation {
310
313
DeviationRecord getADeviationRecord ( ) {
311
314
this = TSingleLineDeviation ( result , _, _, _)
312
315
or
313
- this = TMultiLineDeviation ( result , _, _, _, _, _, _)
316
+ this = TMultiLineDeviation ( result , _, _, _, _, _, _, _ )
314
317
or
315
318
this = TCodeIdentifierDeviation ( result , _)
316
319
}
@@ -330,18 +333,29 @@ class CodeIdentifierDeviation extends TCodeIndentifierDeviation {
330
333
suppressedLine = elementLocationStart
331
334
)
332
335
or
333
- exists ( int suppressedStartLine , int suppressedEndLine , int suppressedEndColumn |
334
- this =
335
- TMultiLineDeviation ( _, _, _, filepath , suppressedStartLine , suppressedEndLine ,
336
- suppressedEndColumn ) and
337
- suppressedStartLine < elementLocationStart
336
+ exists (
337
+ int suppressedStartLine , int suppressedStartColumn , int suppressedEndLine ,
338
+ int suppressedEndColumn
338
339
|
339
- // Element starts before the end line of the suppression
340
- suppressedEndLine > elementLocationStart
341
- or
342
- // Element exists on the same line as the suppression, and occurs before it
343
- suppressedEndLine = elementLocationStart and
344
- elementLocationColumnStart < suppressedEndColumn
340
+ this =
341
+ TMultiLineDeviation ( _, _, _, filepath , suppressedStartLine , suppressedStartColumn ,
342
+ suppressedEndLine , suppressedEndColumn ) and
343
+ (
344
+ // Element starts on a line after the begin marker of the suppression
345
+ suppressedStartLine < elementLocationStart
346
+ or
347
+ // Element exists on the same line as the begin marker, and occurs after it
348
+ suppressedStartLine = elementLocationStart and
349
+ suppressedStartColumn < elementLocationColumnStart
350
+ ) and
351
+ (
352
+ // Element starts on a line before the end marker of the suppression
353
+ suppressedEndLine > elementLocationStart
354
+ or
355
+ // Element exists on the same line as the end marker of the suppression, and occurs before it
356
+ suppressedEndLine = elementLocationStart and
357
+ elementLocationColumnStart < suppressedEndColumn
358
+ )
345
359
)
346
360
)
347
361
or
@@ -371,8 +385,8 @@ class CodeIdentifierDeviation extends TCodeIndentifierDeviation {
371
385
endcolumn = getLastColumnNumber ( filepath , suppressedLine )
372
386
)
373
387
or
374
- this = TMultiLineDeviation ( _ , _ , _ , filepath , suppressedLine , endline , endcolumn ) and
375
- suppressedColumn = 1
388
+ this =
389
+ TMultiLineDeviation ( _ , _ , _ , filepath , suppressedLine , suppressedColumn , endline , endcolumn )
376
390
or
377
391
exists ( DeviationAttribute attribute |
378
392
this = TCodeIdentifierDeviation ( _, attribute ) and
@@ -392,13 +406,17 @@ class CodeIdentifierDeviation extends TCodeIndentifierDeviation {
392
406
suppressedLine
393
407
)
394
408
or
395
- exists ( int suppressedStartLine , int suppressedEndLine , int suppressedEndColumn |
409
+ exists (
410
+ int suppressedStartLine , int suppressedStartColumn , int suppressedEndLine ,
411
+ int suppressedEndColumn
412
+ |
396
413
this =
397
- TMultiLineDeviation ( _, _, _, filepath , suppressedStartLine , suppressedEndLine ,
398
- suppressedEndColumn ) and
414
+ TMultiLineDeviation ( _, _, _, filepath , suppressedStartLine , suppressedStartColumn ,
415
+ suppressedEndLine , suppressedEndColumn ) and
399
416
result =
400
417
"Deviation of " + getADeviationRecord ( ) .getQuery ( ) + " applied to " + filepath + " Line " +
401
- suppressedStartLine + ":" + suppressedEndLine + " (Column " + suppressedEndColumn + ")"
418
+ suppressedStartLine + ":" + suppressedStartColumn + ":" + suppressedEndLine + ":" +
419
+ suppressedEndColumn
402
420
)
403
421
)
404
422
or
0 commit comments