mirror of
https://github.com/github/codeql.git
synced 2026-05-05 13:45:19 +02:00
C#: Base Useless Code tests on stubs.
This commit is contained in:
@@ -8,7 +8,7 @@ class MyDefaultToStringType extends DefaultToStringType {
|
||||
string filepath, int startline, int startcolumn, int endline, int endcolumn
|
||||
) {
|
||||
exists(Location l | l = this.getLocation() |
|
||||
if l instanceof SourceLocation
|
||||
if this.fromSource()
|
||||
then l.hasLocationInfo(filepath, startline, startcolumn, endline, endcolumn)
|
||||
else
|
||||
any(EmptyLocation el).hasLocationInfo(filepath, startline, startcolumn, endline, endcolumn)
|
||||
|
||||
Reference in New Issue
Block a user