Skip to content

Commit f3eed4a

Browse files
authored
Merge pull request #163 from calumgrant/cs/extractor-fixes
C#: Add tests for extractor fixes, and improve CFG for ConstCases
2 parents 10329fa + 58cf95b commit f3eed4a

38 files changed

+500
-190
lines changed

change-notes/1.18/analysis-csharp.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,10 @@
3636

3737
## Changes to code extraction
3838

39+
* The `into` part of `join` clauses is now extracted.
40+
* The `when` part of constant cases is now extracted.
41+
* Fixed a bug where `while(x is T y) ...` was not extracted correctly.
42+
3943
* *Series of bullet points*
4044

4145
## Changes to QL libraries
@@ -59,3 +63,4 @@
5963
- `ControlFlowEdgeGotoCase` has been renamed to `ControlFlow::SuccessorTypes::GotoCaseSuccessor`.
6064
- `ControlFlowEdgeGotoDefault` has been renamed to `ControlFlow::SuccessorTypes::GotoDefaultSuccessor`.
6165
- `ControlFlowEdgeException` has been renamed to `ControlFlow::SuccessorTypes::ExceptionSuccessor`.
66+
* The predicate `getCondition()` has been moved from `TypeCase` to `CaseStmt`. It is now possible to get the condition of a `ConstCase` using its `getCondition()` predicate.

csharp/ql/src/semmle/code/csharp/Stmt.qll

Lines changed: 27 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,25 @@ class SwitchStmt extends SelectionStmt, @switch_stmt {
250250
* A `case` statement. Either a constant case (`ConstCase`), a type matching
251251
* case (`TypeCase`), or a `default` case (`DefaultCase`).
252252
*/
253-
class CaseStmt extends Stmt, @case { }
253+
class CaseStmt extends Stmt, @case {
254+
/**
255+
* Gets the condition on this case, if any. For example, the type case on line 3
256+
* has no condition, and the type case on line 4 has condition `s.Length > 0`, in
257+
*
258+
* ```
259+
* switch(p)
260+
* {
261+
* case int i:
262+
* case string s when s.Length > 0:
263+
* break;
264+
* ...
265+
* }
266+
* ```
267+
*/
268+
Expr getCondition() {
269+
result = this.getChild(2)
270+
}
271+
}
254272

255273
/**
256274
* A constant case of a `switch` statement, for example `case OpCode.Nop:`
@@ -280,15 +298,16 @@ class ConstCase extends LabeledStmt, CaseStmt {
280298
}
281299

282300
/**
283-
* A type matching case in a `switch` statement, for example `case int i:` on line 2 or
284-
* `case string s when s.Length>0:` on line 3 in
301+
* A type matching case in a `switch` statement, for example `case int i:` on line 3 or
302+
* `case string s when s.Length > 0:` on line 4 in
285303
*
286304
* ```
287-
* switch(p) {
288-
* case int i:
289-
* case string s when s.Length>0:
290-
* break;
291-
* ...
305+
* switch(p)
306+
* {
307+
* case int i:
308+
* case string s when s.Length > 0:
309+
* break;
310+
* ...
292311
* }
293312
* ```
294313
*/
@@ -350,23 +369,6 @@ class TypeCase extends LabeledStmt, CaseStmt {
350369
result = getTypeAccess().getType()
351370
}
352371

353-
/**
354-
* Gets the condition on this case, if any. For example, the type case on line 2
355-
* has no condition, and the type case on line 3 has condition `s.Length>0`, in
356-
*
357-
* ```
358-
* switch(p) {
359-
* case int i:
360-
* case string s when s.Length>0:
361-
* break;
362-
* ...
363-
* }
364-
* ```
365-
*/
366-
Expr getCondition() {
367-
result = getChild(2)
368-
}
369-
370372
override string toString() {
371373
exists(string var |
372374
if exists(this.getVariableDeclExpr()) then

csharp/ql/src/semmle/code/csharp/controlflow/Completion.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -309,8 +309,8 @@ private predicate inBooleanContext(Expr e, boolean isBooleanCompletionForParent)
309309
isBooleanCompletionForParent = false
310310
)
311311
or
312-
exists(TypeCase tc |
313-
tc.getCondition() = e |
312+
exists(CaseStmt cs |
313+
cs.getCondition() = e |
314314
isBooleanCompletionForParent = false
315315
)
316316
or

csharp/ql/src/semmle/code/csharp/controlflow/ControlFlowGraph.qll

Lines changed: 27 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1272,25 +1272,24 @@ module ControlFlow {
12721272
// Case expression exits abnormally
12731273
result = lastConstCaseExpr(cc, c) and
12741274
not c instanceof NormalCompletion
1275-
or
1276-
// Case statement exits with any completion
1277-
result = lastConstCaseStmt(cc, c)
12781275
)
12791276
or
12801277
cfe = any(TypeCase tc |
12811278
// Type test exits with a non-match
12821279
result = lastTypeCaseNoMatch(tc, c)
1283-
or
1280+
)
1281+
or
1282+
cfe = any(CaseStmt cs |
12841283
// Condition exists with a `false` completion
1285-
result = lastTypeCaseCondition(tc, c) and
1284+
result = lastCaseCondition(cs, c) and
12861285
c instanceof FalseCompletion
12871286
or
12881287
// Condition exists abnormally
1289-
result = lastTypeCaseCondition(tc, c) and
1288+
result = lastCaseCondition(cs, c) and
12901289
not c instanceof NormalCompletion
12911290
or
12921291
// Case statement exits with any completion
1293-
result = lastTypeCaseStmt(tc, c)
1292+
result = lastCaseStmt(cs, c)
12941293
)
12951294
or
12961295
exists(LoopStmt ls |
@@ -1576,25 +1575,22 @@ module ControlFlow {
15761575
}
15771576

15781577
pragma [nomagic]
1579-
private ControlFlowElement lastConstCaseStmt(ConstCase cc, Completion c) {
1580-
result = last(cc.getStmt(), c)
1578+
private ControlFlowElement lastCaseStmt(CaseStmt cs, Completion c) {
1579+
result = last(cs.(TypeCase).getStmt(), c)
1580+
or
1581+
result = last(cs.(ConstCase).getStmt(), c)
15811582
}
15821583

15831584
pragma [nomagic]
1584-
private ControlFlowElement lastTypeCaseCondition(TypeCase tc, Completion c) {
1585-
result = last(tc.getCondition(), c)
1585+
private ControlFlowElement lastCaseCondition(CaseStmt cs, Completion c) {
1586+
result = last(cs.getCondition(), c)
15861587
}
15871588

15881589
pragma [nomagic]
15891590
private ControlFlowElement lastTypeCaseVariableDeclExpr(TypeCase tc, Completion c) {
15901591
result = last(tc.getVariableDeclExpr(), c)
15911592
}
15921593

1593-
pragma [nomagic]
1594-
private ControlFlowElement lastTypeCaseStmt(TypeCase tc, Completion c) {
1595-
result = last(tc.getStmt(), c)
1596-
}
1597-
15981594
pragma [nomagic]
15991595
private ControlFlowElement lastLoopStmtCondition(LoopStmt ls, Completion c) {
16001596
result = last(ls.getCondition(), c)
@@ -2032,9 +2028,9 @@ module ControlFlow {
20322028
)
20332029
or
20342030
// Flow from last element of condition to next case
2035-
exists(TypeCase tc, int i |
2031+
exists(CaseStmt tc, int i |
20362032
tc = ss.getCase(i) |
2037-
cfe = lastTypeCaseCondition(tc, c) and
2033+
cfe = lastCaseCondition(tc, c) and
20382034
c instanceof FalseCompletion and
20392035
result = first(ss.getCase(i + 1))
20402036
)
@@ -2063,9 +2059,19 @@ module ControlFlow {
20632059
result = first(cc.getExpr()) and
20642060
c instanceof SimpleCompletion
20652061
or
2066-
// Flow from last element of case expression to first element of statement
20672062
cfe = lastConstCaseExpr(cc, c) and
2068-
c.(MatchingCompletion).isMatch() and
2063+
c.(MatchingCompletion).isMatch() and (
2064+
if exists(cc.getCondition()) then
2065+
// Flow from the last element of case expression to the condition
2066+
result = first(cc.getCondition())
2067+
else
2068+
// Flow from last element of case expression to first element of statement
2069+
result = first(cc.getStmt())
2070+
)
2071+
or
2072+
// Flow from last element of case condition to first element of statement
2073+
cfe = lastCaseCondition(cc, c) and
2074+
c instanceof TrueCompletion and
20692075
result = first(cc.getStmt())
20702076
)
20712077
or
@@ -2105,7 +2111,7 @@ module ControlFlow {
21052111
result = first(tc.getStmt())
21062112
or
21072113
// Flow from condition to first element of statement
2108-
cfe = lastTypeCaseCondition(tc, c) and
2114+
cfe = lastCaseCondition(tc, c) and
21092115
c instanceof TrueCompletion and
21102116
result = first(tc.getStmt())
21112117
)

csharp/ql/test/library-tests/controlflow/graph/BasicBlock.expected

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,14 @@
245245
| Switch.cs:106:29:106:29 | 1 | Switch.cs:106:22:106:30 | return ...; | 2 |
246246
| Switch.cs:108:17:108:17 | 1 | Switch.cs:108:9:108:18 | return ...; | 3 |
247247
| Switch.cs:111:17:111:21 | enter Throw | Switch.cs:111:17:111:21 | exit Throw | 4 |
248+
| Switch.cs:113:9:113:11 | enter M10 | Switch.cs:117:18:117:18 | 3 | 7 |
249+
| Switch.cs:113:9:113:11 | exit M10 | Switch.cs:113:9:113:11 | exit M10 | 1 |
250+
| Switch.cs:117:25:117:25 | access to parameter s | Switch.cs:117:25:117:32 | ... == ... | 3 |
251+
| Switch.cs:117:43:117:43 | 1 | Switch.cs:117:36:117:44 | return ...; | 2 |
252+
| Switch.cs:118:13:118:33 | case ...: | Switch.cs:118:18:118:18 | 2 | 2 |
253+
| Switch.cs:118:25:118:25 | access to parameter s | Switch.cs:118:25:118:31 | ... == ... | 3 |
254+
| Switch.cs:118:42:118:42 | 2 | Switch.cs:118:35:118:43 | return ...; | 2 |
255+
| Switch.cs:120:17:120:17 | 1 | Switch.cs:120:9:120:18 | return ...; | 3 |
248256
| TypeAccesses.cs:3:10:3:10 | enter M | TypeAccesses.cs:7:13:7:22 | ... is ... | 16 |
249257
| TypeAccesses.cs:7:25:7:25 | ; | TypeAccesses.cs:7:25:7:25 | ; | 1 |
250258
| TypeAccesses.cs:8:9:8:28 | ... ...; | TypeAccesses.cs:3:10:3:10 | exit M | 5 |

csharp/ql/test/library-tests/controlflow/graph/BasicBlockDominance.expected

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -470,6 +470,21 @@
470470
| post | Switch.cs:106:29:106:29 | 1 | Switch.cs:106:29:106:29 | 1 |
471471
| post | Switch.cs:108:17:108:17 | 1 | Switch.cs:108:17:108:17 | 1 |
472472
| post | Switch.cs:111:17:111:21 | enter Throw | Switch.cs:111:17:111:21 | enter Throw |
473+
| post | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:113:9:113:11 | enter M10 |
474+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:113:9:113:11 | enter M10 |
475+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:113:9:113:11 | exit M10 |
476+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:117:25:117:25 | access to parameter s |
477+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:117:43:117:43 | 1 |
478+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:118:13:118:33 | case ...: |
479+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:118:25:118:25 | access to parameter s |
480+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:118:42:118:42 | 2 |
481+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:120:17:120:17 | 1 |
482+
| post | Switch.cs:117:25:117:25 | access to parameter s | Switch.cs:117:25:117:25 | access to parameter s |
483+
| post | Switch.cs:117:43:117:43 | 1 | Switch.cs:117:43:117:43 | 1 |
484+
| post | Switch.cs:118:13:118:33 | case ...: | Switch.cs:118:13:118:33 | case ...: |
485+
| post | Switch.cs:118:25:118:25 | access to parameter s | Switch.cs:118:25:118:25 | access to parameter s |
486+
| post | Switch.cs:118:42:118:42 | 2 | Switch.cs:118:42:118:42 | 2 |
487+
| post | Switch.cs:120:17:120:17 | 1 | Switch.cs:120:17:120:17 | 1 |
473488
| post | TypeAccesses.cs:3:10:3:10 | enter M | TypeAccesses.cs:3:10:3:10 | enter M |
474489
| post | TypeAccesses.cs:7:25:7:25 | ; | TypeAccesses.cs:7:25:7:25 | ; |
475490
| post | TypeAccesses.cs:8:9:8:28 | ... ...; | TypeAccesses.cs:3:10:3:10 | enter M |
@@ -1709,6 +1724,26 @@
17091724
| pre | Switch.cs:106:29:106:29 | 1 | Switch.cs:106:29:106:29 | 1 |
17101725
| pre | Switch.cs:108:17:108:17 | 1 | Switch.cs:108:17:108:17 | 1 |
17111726
| pre | Switch.cs:111:17:111:21 | enter Throw | Switch.cs:111:17:111:21 | enter Throw |
1727+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:113:9:113:11 | enter M10 |
1728+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:113:9:113:11 | exit M10 |
1729+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:117:25:117:25 | access to parameter s |
1730+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:117:43:117:43 | 1 |
1731+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:118:13:118:33 | case ...: |
1732+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:118:25:118:25 | access to parameter s |
1733+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:118:42:118:42 | 2 |
1734+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:120:17:120:17 | 1 |
1735+
| pre | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:113:9:113:11 | exit M10 |
1736+
| pre | Switch.cs:117:25:117:25 | access to parameter s | Switch.cs:117:25:117:25 | access to parameter s |
1737+
| pre | Switch.cs:117:25:117:25 | access to parameter s | Switch.cs:117:43:117:43 | 1 |
1738+
| pre | Switch.cs:117:43:117:43 | 1 | Switch.cs:117:43:117:43 | 1 |
1739+
| pre | Switch.cs:118:13:118:33 | case ...: | Switch.cs:118:13:118:33 | case ...: |
1740+
| pre | Switch.cs:118:13:118:33 | case ...: | Switch.cs:118:25:118:25 | access to parameter s |
1741+
| pre | Switch.cs:118:13:118:33 | case ...: | Switch.cs:118:42:118:42 | 2 |
1742+
| pre | Switch.cs:118:13:118:33 | case ...: | Switch.cs:120:17:120:17 | 1 |
1743+
| pre | Switch.cs:118:25:118:25 | access to parameter s | Switch.cs:118:25:118:25 | access to parameter s |
1744+
| pre | Switch.cs:118:25:118:25 | access to parameter s | Switch.cs:118:42:118:42 | 2 |
1745+
| pre | Switch.cs:118:42:118:42 | 2 | Switch.cs:118:42:118:42 | 2 |
1746+
| pre | Switch.cs:120:17:120:17 | 1 | Switch.cs:120:17:120:17 | 1 |
17121747
| pre | TypeAccesses.cs:3:10:3:10 | enter M | TypeAccesses.cs:3:10:3:10 | enter M |
17131748
| pre | TypeAccesses.cs:3:10:3:10 | enter M | TypeAccesses.cs:7:25:7:25 | ; |
17141749
| pre | TypeAccesses.cs:3:10:3:10 | enter M | TypeAccesses.cs:8:9:8:28 | ... ...; |

csharp/ql/test/library-tests/controlflow/graph/ConditionBlock.expected

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,8 @@
8989
| Switch.cs:50:30:50:38 | ... != ... | Switch.cs:51:17:51:22 | break; | true |
9090
| Switch.cs:84:19:84:23 | ... > ... | Switch.cs:85:17:85:22 | break; | true |
9191
| Switch.cs:84:19:84:23 | ... > ... | Switch.cs:86:22:86:25 | true | false |
92+
| Switch.cs:117:25:117:32 | ... == ... | Switch.cs:117:43:117:43 | 1 | true |
93+
| Switch.cs:118:25:118:31 | ... == ... | Switch.cs:118:42:118:42 | 2 | true |
9294
| TypeAccesses.cs:7:13:7:22 | ... is ... | TypeAccesses.cs:7:25:7:25 | ; | true |
9395
| VarDecls.cs:25:20:25:20 | access to parameter b | VarDecls.cs:25:24:25:24 | access to local variable x | true |
9496
| VarDecls.cs:25:20:25:20 | access to parameter b | VarDecls.cs:25:28:25:28 | access to local variable y | false |

csharp/ql/test/library-tests/controlflow/graph/ConditionalFlow.expected

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,10 @@
117117
| 108 | 13 | cflow.cs:108:13:108:21 | ... != ... | false | 116 | 9 | cflow.cs:116:9:116:29 | ...; |
118118
| 108 | 13 | cflow.cs:108:13:108:21 | ... != ... | true | 109 | 9 | cflow.cs:109:9:115:9 | {...} |
119119
| 110 | 20 | cflow.cs:110:20:110:23 | true | true | 111 | 13 | cflow.cs:111:13:113:13 | {...} |
120+
| 117 | 25 | Switch.cs:117:25:117:32 | ... == ... | false | 118 | 13 | Switch.cs:118:13:118:33 | case ...: |
121+
| 117 | 25 | Switch.cs:117:25:117:32 | ... == ... | true | 117 | 43 | Switch.cs:117:43:117:43 | 1 |
122+
| 118 | 25 | Switch.cs:118:25:118:31 | ... == ... | false | 120 | 17 | Switch.cs:120:17:120:17 | 1 |
123+
| 118 | 25 | Switch.cs:118:25:118:31 | ... == ... | true | 118 | 42 | Switch.cs:118:42:118:42 | 2 |
120124
| 127 | 32 | cflow.cs:127:32:127:44 | ... == ... | false | 127 | 53 | cflow.cs:127:53:127:57 | this access |
121125
| 127 | 32 | cflow.cs:127:32:127:44 | ... == ... | true | 127 | 48 | cflow.cs:127:48:127:49 | "" |
122126
| 162 | 48 | cflow.cs:162:48:162:51 | [exception: Exception] true | true | 163 | 9 | cflow.cs:163:9:165:9 | {...} |

csharp/ql/test/library-tests/controlflow/graph/Dominance.expected

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -819,6 +819,24 @@
819819
| post | Switch.cs:111:17:111:21 | exit Throw | Switch.cs:111:28:111:48 | throw ... |
820820
| post | Switch.cs:111:28:111:48 | throw ... | Switch.cs:111:34:111:48 | object creation of type Exception |
821821
| post | Switch.cs:111:34:111:48 | object creation of type Exception | Switch.cs:111:17:111:21 | enter Throw |
822+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:117:36:117:44 | return ...; |
823+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:118:35:118:43 | return ...; |
824+
| post | Switch.cs:113:9:113:11 | exit M10 | Switch.cs:120:9:120:18 | return ...; |
825+
| post | Switch.cs:114:5:121:5 | {...} | Switch.cs:113:9:113:11 | enter M10 |
826+
| post | Switch.cs:115:9:119:9 | switch (...) {...} | Switch.cs:114:5:121:5 | {...} |
827+
| post | Switch.cs:115:17:115:17 | access to parameter s | Switch.cs:115:9:119:9 | switch (...) {...} |
828+
| post | Switch.cs:115:17:115:24 | access to property Length | Switch.cs:115:17:115:17 | access to parameter s |
829+
| post | Switch.cs:117:13:117:34 | case ...: | Switch.cs:115:17:115:24 | access to property Length |
830+
| post | Switch.cs:117:18:117:18 | 3 | Switch.cs:117:13:117:34 | case ...: |
831+
| post | Switch.cs:117:25:117:32 | ... == ... | Switch.cs:117:28:117:32 | "foo" |
832+
| post | Switch.cs:117:28:117:32 | "foo" | Switch.cs:117:25:117:25 | access to parameter s |
833+
| post | Switch.cs:117:36:117:44 | return ...; | Switch.cs:117:43:117:43 | 1 |
834+
| post | Switch.cs:118:18:118:18 | 2 | Switch.cs:118:13:118:33 | case ...: |
835+
| post | Switch.cs:118:25:118:31 | ... == ... | Switch.cs:118:28:118:31 | "fu" |
836+
| post | Switch.cs:118:28:118:31 | "fu" | Switch.cs:118:25:118:25 | access to parameter s |
837+
| post | Switch.cs:118:35:118:43 | return ...; | Switch.cs:118:42:118:42 | 2 |
838+
| post | Switch.cs:120:9:120:18 | return ...; | Switch.cs:120:16:120:17 | -... |
839+
| post | Switch.cs:120:16:120:17 | -... | Switch.cs:120:17:120:17 | 1 |
822840
| post | TypeAccesses.cs:3:10:3:10 | exit M | TypeAccesses.cs:8:13:8:27 | Type t = ... |
823841
| post | TypeAccesses.cs:4:5:9:5 | {...} | TypeAccesses.cs:3:10:3:10 | enter M |
824842
| post | TypeAccesses.cs:5:9:5:26 | ... ...; | TypeAccesses.cs:4:5:9:5 | {...} |
@@ -2643,6 +2661,27 @@
26432661
| pre | Switch.cs:111:17:111:21 | enter Throw | Switch.cs:111:34:111:48 | object creation of type Exception |
26442662
| pre | Switch.cs:111:28:111:48 | throw ... | Switch.cs:111:17:111:21 | exit Throw |
26452663
| pre | Switch.cs:111:34:111:48 | object creation of type Exception | Switch.cs:111:28:111:48 | throw ... |
2664+
| pre | Switch.cs:113:9:113:11 | enter M10 | Switch.cs:114:5:121:5 | {...} |
2665+
| pre | Switch.cs:114:5:121:5 | {...} | Switch.cs:115:9:119:9 | switch (...) {...} |
2666+
| pre | Switch.cs:115:9:119:9 | switch (...) {...} | Switch.cs:115:17:115:17 | access to parameter s |
2667+
| pre | Switch.cs:115:17:115:17 | access to parameter s | Switch.cs:115:17:115:24 | access to property Length |
2668+
| pre | Switch.cs:115:17:115:24 | access to property Length | Switch.cs:117:13:117:34 | case ...: |
2669+
| pre | Switch.cs:117:13:117:34 | case ...: | Switch.cs:117:18:117:18 | 3 |
2670+
| pre | Switch.cs:117:18:117:18 | 3 | Switch.cs:117:25:117:25 | access to parameter s |
2671+
| pre | Switch.cs:117:18:117:18 | 3 | Switch.cs:118:13:118:33 | case ...: |
2672+
| pre | Switch.cs:117:25:117:25 | access to parameter s | Switch.cs:117:28:117:32 | "foo" |
2673+
| pre | Switch.cs:117:25:117:32 | ... == ... | Switch.cs:117:43:117:43 | 1 |
2674+
| pre | Switch.cs:117:28:117:32 | "foo" | Switch.cs:117:25:117:32 | ... == ... |
2675+
| pre | Switch.cs:117:43:117:43 | 1 | Switch.cs:117:36:117:44 | return ...; |
2676+
| pre | Switch.cs:118:13:118:33 | case ...: | Switch.cs:118:18:118:18 | 2 |
2677+
| pre | Switch.cs:118:18:118:18 | 2 | Switch.cs:118:25:118:25 | access to parameter s |
2678+
| pre | Switch.cs:118:18:118:18 | 2 | Switch.cs:120:17:120:17 | 1 |
2679+
| pre | Switch.cs:118:25:118:25 | access to parameter s | Switch.cs:118:28:118:31 | "fu" |
2680+
| pre | Switch.cs:118:25:118:31 | ... == ... | Switch.cs:118:42:118:42 | 2 |
2681+
| pre | Switch.cs:118:28:118:31 | "fu" | Switch.cs:118:25:118:31 | ... == ... |
2682+
| pre | Switch.cs:118:42:118:42 | 2 | Switch.cs:118:35:118:43 | return ...; |
2683+
| pre | Switch.cs:120:16:120:17 | -... | Switch.cs:120:9:120:18 | return ...; |
2684+
| pre | Switch.cs:120:17:120:17 | 1 | Switch.cs:120:16:120:17 | -... |
26462685
| pre | TypeAccesses.cs:3:10:3:10 | enter M | TypeAccesses.cs:4:5:9:5 | {...} |
26472686
| pre | TypeAccesses.cs:4:5:9:5 | {...} | TypeAccesses.cs:5:9:5:26 | ... ...; |
26482687
| pre | TypeAccesses.cs:5:9:5:26 | ... ...; | TypeAccesses.cs:5:13:5:13 | access to local variable s |

0 commit comments

Comments
 (0)