File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed
csharp/ql/src/semmle/code/csharp/dataflow Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ module DataFlow {
2828 DotNet:: Type getType ( ) { none ( ) }
2929
3030 /** Gets the enclosing callable of this node. */
31+ cached
3132 DotNet:: Callable getEnclosingCallable ( ) { none ( ) }
3233
3334 /** Gets a textual representation of this node. */
@@ -52,9 +53,19 @@ module DataFlow {
5253
5354 override DotNet:: Callable getEnclosingCallable ( ) { result = expr .getEnclosingCallable ( ) }
5455
55- override string toString ( ) { result = expr .toString ( ) }
56+ override string toString ( ) {
57+ result = expr .( Expr ) .toString ( )
58+ or
59+ expr instanceof CIL:: Expr and
60+ result = "CIL expression"
61+ }
5662
57- override Location getLocation ( ) { result = expr .getLocation ( ) }
63+ override Location getLocation ( ) {
64+ result = expr .( Expr ) .getLocation ( )
65+ or
66+ result .getFile ( ) .isPdbSourceFile ( ) and
67+ result = expr .( CIL:: Expr ) .getALocation ( )
68+ }
5869 }
5970
6071 /**
You can’t perform that action at this time.
0 commit comments