Skip to content

Commit 72b3514

Browse files
committed
C#: Add CFG tests for foreach statements with multipe variable declarations
1 parent 79e246f commit 72b3514

File tree

10 files changed

+195
-0
lines changed

10 files changed

+195
-0
lines changed

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

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,18 @@
231231
| Foreach.cs:20:22:20:22 | String x | Foreach.cs:21:11:21:11 | ; | 2 |
232232
| Foreach.cs:20:29:20:38 | call to method ToArray | Foreach.cs:20:29:20:38 | call to method ToArray | 1 |
233233
| Foreach.cs:20:43:20:68 | call to method Empty | Foreach.cs:20:43:20:68 | call to method Empty | 1 |
234+
| Foreach.cs:24:10:24:11 | enter M4 | Foreach.cs:26:36:26:39 | access to parameter args | 3 |
235+
| Foreach.cs:24:10:24:11 | exit M4 | Foreach.cs:24:10:24:11 | exit M4 | 1 |
236+
| Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | 1 |
237+
| Foreach.cs:27:11:27:11 | ; | Foreach.cs:27:11:27:11 | ; | 1 |
238+
| Foreach.cs:30:10:30:11 | enter M5 | Foreach.cs:32:32:32:35 | access to parameter args | 3 |
239+
| Foreach.cs:30:10:30:11 | exit M5 | Foreach.cs:30:10:30:11 | exit M5 | 1 |
240+
| Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | 1 |
241+
| Foreach.cs:33:11:33:11 | ; | Foreach.cs:33:11:33:11 | ; | 1 |
242+
| Foreach.cs:36:10:36:11 | enter M6 | Foreach.cs:38:39:38:42 | access to parameter args | 3 |
243+
| Foreach.cs:36:10:36:11 | exit M6 | Foreach.cs:36:10:36:11 | exit M6 | 1 |
244+
| Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | 1 |
245+
| Foreach.cs:39:11:39:11 | ; | Foreach.cs:39:11:39:11 | ; | 1 |
234246
| Initializers.cs:6:5:6:16 | enter Initializers | Initializers.cs:6:5:6:16 | exit Initializers | 3 |
235247
| Initializers.cs:8:10:8:10 | enter M | Initializers.cs:8:10:8:10 | exit M | 23 |
236248
| NullCoalescing.cs:3:9:3:10 | enter M1 | NullCoalescing.cs:3:23:3:23 | access to parameter i | 3 |

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

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -477,6 +477,33 @@
477477
| post | Foreach.cs:20:22:20:22 | String x | Foreach.cs:20:22:20:22 | String x |
478478
| post | Foreach.cs:20:29:20:38 | call to method ToArray | Foreach.cs:20:29:20:38 | call to method ToArray |
479479
| post | Foreach.cs:20:43:20:68 | call to method Empty | Foreach.cs:20:43:20:68 | call to method Empty |
480+
| post | Foreach.cs:24:10:24:11 | enter M4 | Foreach.cs:24:10:24:11 | enter M4 |
481+
| post | Foreach.cs:24:10:24:11 | exit M4 | Foreach.cs:24:10:24:11 | enter M4 |
482+
| post | Foreach.cs:24:10:24:11 | exit M4 | Foreach.cs:24:10:24:11 | exit M4 |
483+
| post | Foreach.cs:24:10:24:11 | exit M4 | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... |
484+
| post | Foreach.cs:24:10:24:11 | exit M4 | Foreach.cs:27:11:27:11 | ; |
485+
| post | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:24:10:24:11 | enter M4 |
486+
| post | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... |
487+
| post | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:27:11:27:11 | ; |
488+
| post | Foreach.cs:27:11:27:11 | ; | Foreach.cs:27:11:27:11 | ; |
489+
| post | Foreach.cs:30:10:30:11 | enter M5 | Foreach.cs:30:10:30:11 | enter M5 |
490+
| post | Foreach.cs:30:10:30:11 | exit M5 | Foreach.cs:30:10:30:11 | enter M5 |
491+
| post | Foreach.cs:30:10:30:11 | exit M5 | Foreach.cs:30:10:30:11 | exit M5 |
492+
| post | Foreach.cs:30:10:30:11 | exit M5 | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... |
493+
| post | Foreach.cs:30:10:30:11 | exit M5 | Foreach.cs:33:11:33:11 | ; |
494+
| post | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:30:10:30:11 | enter M5 |
495+
| post | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... |
496+
| post | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:33:11:33:11 | ; |
497+
| post | Foreach.cs:33:11:33:11 | ; | Foreach.cs:33:11:33:11 | ; |
498+
| post | Foreach.cs:36:10:36:11 | enter M6 | Foreach.cs:36:10:36:11 | enter M6 |
499+
| post | Foreach.cs:36:10:36:11 | exit M6 | Foreach.cs:36:10:36:11 | enter M6 |
500+
| post | Foreach.cs:36:10:36:11 | exit M6 | Foreach.cs:36:10:36:11 | exit M6 |
501+
| post | Foreach.cs:36:10:36:11 | exit M6 | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... |
502+
| post | Foreach.cs:36:10:36:11 | exit M6 | Foreach.cs:39:11:39:11 | ; |
503+
| post | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:36:10:36:11 | enter M6 |
504+
| post | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... |
505+
| post | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:39:11:39:11 | ; |
506+
| post | Foreach.cs:39:11:39:11 | ; | Foreach.cs:39:11:39:11 | ; |
480507
| post | Initializers.cs:6:5:6:16 | enter Initializers | Initializers.cs:6:5:6:16 | enter Initializers |
481508
| post | Initializers.cs:8:10:8:10 | enter M | Initializers.cs:8:10:8:10 | enter M |
482509
| post | NullCoalescing.cs:3:9:3:10 | enter M1 | NullCoalescing.cs:3:9:3:10 | enter M1 |
@@ -1856,6 +1883,33 @@
18561883
| pre | Foreach.cs:20:22:20:22 | String x | Foreach.cs:20:22:20:22 | String x |
18571884
| pre | Foreach.cs:20:29:20:38 | call to method ToArray | Foreach.cs:20:29:20:38 | call to method ToArray |
18581885
| pre | Foreach.cs:20:43:20:68 | call to method Empty | Foreach.cs:20:43:20:68 | call to method Empty |
1886+
| pre | Foreach.cs:24:10:24:11 | enter M4 | Foreach.cs:24:10:24:11 | enter M4 |
1887+
| pre | Foreach.cs:24:10:24:11 | enter M4 | Foreach.cs:24:10:24:11 | exit M4 |
1888+
| pre | Foreach.cs:24:10:24:11 | enter M4 | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... |
1889+
| pre | Foreach.cs:24:10:24:11 | enter M4 | Foreach.cs:27:11:27:11 | ; |
1890+
| pre | Foreach.cs:24:10:24:11 | exit M4 | Foreach.cs:24:10:24:11 | exit M4 |
1891+
| pre | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:24:10:24:11 | exit M4 |
1892+
| pre | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... |
1893+
| pre | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:27:11:27:11 | ; |
1894+
| pre | Foreach.cs:27:11:27:11 | ; | Foreach.cs:27:11:27:11 | ; |
1895+
| pre | Foreach.cs:30:10:30:11 | enter M5 | Foreach.cs:30:10:30:11 | enter M5 |
1896+
| pre | Foreach.cs:30:10:30:11 | enter M5 | Foreach.cs:30:10:30:11 | exit M5 |
1897+
| pre | Foreach.cs:30:10:30:11 | enter M5 | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... |
1898+
| pre | Foreach.cs:30:10:30:11 | enter M5 | Foreach.cs:33:11:33:11 | ; |
1899+
| pre | Foreach.cs:30:10:30:11 | exit M5 | Foreach.cs:30:10:30:11 | exit M5 |
1900+
| pre | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:30:10:30:11 | exit M5 |
1901+
| pre | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... |
1902+
| pre | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:33:11:33:11 | ; |
1903+
| pre | Foreach.cs:33:11:33:11 | ; | Foreach.cs:33:11:33:11 | ; |
1904+
| pre | Foreach.cs:36:10:36:11 | enter M6 | Foreach.cs:36:10:36:11 | enter M6 |
1905+
| pre | Foreach.cs:36:10:36:11 | enter M6 | Foreach.cs:36:10:36:11 | exit M6 |
1906+
| pre | Foreach.cs:36:10:36:11 | enter M6 | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... |
1907+
| pre | Foreach.cs:36:10:36:11 | enter M6 | Foreach.cs:39:11:39:11 | ; |
1908+
| pre | Foreach.cs:36:10:36:11 | exit M6 | Foreach.cs:36:10:36:11 | exit M6 |
1909+
| pre | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:36:10:36:11 | exit M6 |
1910+
| pre | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... |
1911+
| pre | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:39:11:39:11 | ; |
1912+
| pre | Foreach.cs:39:11:39:11 | ; | Foreach.cs:39:11:39:11 | ; |
18591913
| pre | Initializers.cs:6:5:6:16 | enter Initializers | Initializers.cs:6:5:6:16 | enter Initializers |
18601914
| pre | Initializers.cs:8:10:8:10 | enter M | Initializers.cs:8:10:8:10 | enter M |
18611915
| pre | NullCoalescing.cs:3:9:3:10 | enter M1 | NullCoalescing.cs:3:9:3:10 | enter M1 |

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

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,12 @@
183183
| Foreach.cs:20:9:21:11 | foreach (... ... in ...) ... | Foreach.cs:18:10:18:11 | exit M3 | true |
184184
| Foreach.cs:20:9:21:11 | foreach (... ... in ...) ... | Foreach.cs:20:22:20:22 | String x | false |
185185
| Foreach.cs:20:27:20:27 | access to parameter e | Foreach.cs:20:29:20:38 | call to method ToArray | false |
186+
| Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:24:10:24:11 | exit M4 | true |
187+
| Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:27:11:27:11 | ; | false |
188+
| Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:30:10:30:11 | exit M5 | true |
189+
| Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:33:11:33:11 | ; | false |
190+
| Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:36:10:36:11 | exit M6 | true |
191+
| Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:39:11:39:11 | ; | false |
186192
| NullCoalescing.cs:3:23:3:23 | access to parameter i | NullCoalescing.cs:3:28:3:28 | 0 | true |
187193
| NullCoalescing.cs:5:25:5:25 | access to parameter b | NullCoalescing.cs:5:30:5:34 | false | true |
188194
| NullCoalescing.cs:5:25:5:25 | access to parameter b | NullCoalescing.cs:5:39:5:39 | 0 | true |

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

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -872,6 +872,21 @@
872872
| post | Foreach.cs:20:27:20:27 | access to parameter e | Foreach.cs:20:27:20:68 | ... ?? ... |
873873
| post | Foreach.cs:20:27:20:68 | ... ?? ... | Foreach.cs:19:5:22:5 | {...} |
874874
| post | Foreach.cs:21:11:21:11 | ; | Foreach.cs:20:22:20:22 | String x |
875+
| post | Foreach.cs:24:10:24:11 | exit M4 | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... |
876+
| post | Foreach.cs:25:5:28:5 | {...} | Foreach.cs:24:10:24:11 | enter M4 |
877+
| post | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:26:36:26:39 | access to parameter args |
878+
| post | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:27:11:27:11 | ; |
879+
| post | Foreach.cs:26:36:26:39 | access to parameter args | Foreach.cs:25:5:28:5 | {...} |
880+
| post | Foreach.cs:30:10:30:11 | exit M5 | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... |
881+
| post | Foreach.cs:31:5:34:5 | {...} | Foreach.cs:30:10:30:11 | enter M5 |
882+
| post | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:32:32:32:35 | access to parameter args |
883+
| post | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:33:11:33:11 | ; |
884+
| post | Foreach.cs:32:32:32:35 | access to parameter args | Foreach.cs:31:5:34:5 | {...} |
885+
| post | Foreach.cs:36:10:36:11 | exit M6 | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... |
886+
| post | Foreach.cs:37:5:40:5 | {...} | Foreach.cs:36:10:36:11 | enter M6 |
887+
| post | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:38:39:38:42 | access to parameter args |
888+
| post | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:39:11:39:11 | ; |
889+
| post | Foreach.cs:38:39:38:42 | access to parameter args | Foreach.cs:37:5:40:5 | {...} |
875890
| post | Initializers.cs:6:5:6:16 | exit Initializers | Initializers.cs:6:28:6:30 | {...} |
876891
| post | Initializers.cs:6:28:6:30 | {...} | Initializers.cs:6:5:6:16 | enter Initializers |
877892
| post | Initializers.cs:8:10:8:10 | exit M | Initializers.cs:11:13:11:63 | Initializers[] iz = ... |
@@ -3093,6 +3108,21 @@
30933108
| pre | Foreach.cs:20:27:20:27 | access to parameter e | Foreach.cs:20:29:20:38 | call to method ToArray |
30943109
| pre | Foreach.cs:20:27:20:27 | access to parameter e | Foreach.cs:20:43:20:68 | call to method Empty |
30953110
| pre | Foreach.cs:20:27:20:68 | ... ?? ... | Foreach.cs:20:27:20:27 | access to parameter e |
3111+
| pre | Foreach.cs:24:10:24:11 | enter M4 | Foreach.cs:25:5:28:5 | {...} |
3112+
| pre | Foreach.cs:25:5:28:5 | {...} | Foreach.cs:26:36:26:39 | access to parameter args |
3113+
| pre | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:24:10:24:11 | exit M4 |
3114+
| pre | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:27:11:27:11 | ; |
3115+
| pre | Foreach.cs:26:36:26:39 | access to parameter args | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... |
3116+
| pre | Foreach.cs:30:10:30:11 | enter M5 | Foreach.cs:31:5:34:5 | {...} |
3117+
| pre | Foreach.cs:31:5:34:5 | {...} | Foreach.cs:32:32:32:35 | access to parameter args |
3118+
| pre | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:30:10:30:11 | exit M5 |
3119+
| pre | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:33:11:33:11 | ; |
3120+
| pre | Foreach.cs:32:32:32:35 | access to parameter args | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... |
3121+
| pre | Foreach.cs:36:10:36:11 | enter M6 | Foreach.cs:37:5:40:5 | {...} |
3122+
| pre | Foreach.cs:37:5:40:5 | {...} | Foreach.cs:38:39:38:42 | access to parameter args |
3123+
| pre | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:36:10:36:11 | exit M6 |
3124+
| pre | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:39:11:39:11 | ; |
3125+
| pre | Foreach.cs:38:39:38:42 | access to parameter args | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... |
30963126
| pre | Initializers.cs:6:5:6:16 | enter Initializers | Initializers.cs:6:28:6:30 | {...} |
30973127
| pre | Initializers.cs:6:28:6:30 | {...} | Initializers.cs:6:5:6:16 | exit Initializers |
30983128
| pre | Initializers.cs:8:10:8:10 | enter M | Initializers.cs:9:5:12:5 | {...} |

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

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -664,6 +664,18 @@
664664
| Foreach.cs:20:29:20:38 | call to method ToArray | Foreach.cs:20:43:20:68 | call to method Empty | semmle.label | null |
665665
| Foreach.cs:20:43:20:68 | call to method Empty | Foreach.cs:20:9:21:11 | foreach (... ... in ...) ... | semmle.label | successor |
666666
| Foreach.cs:21:11:21:11 | ; | Foreach.cs:20:9:21:11 | foreach (... ... in ...) ... | semmle.label | successor |
667+
| Foreach.cs:25:5:28:5 | {...} | Foreach.cs:26:36:26:39 | access to parameter args | semmle.label | successor |
668+
| Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:27:11:27:11 | ; | semmle.label | non-empty |
669+
| Foreach.cs:26:36:26:39 | access to parameter args | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | semmle.label | successor |
670+
| Foreach.cs:27:11:27:11 | ; | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | semmle.label | successor |
671+
| Foreach.cs:31:5:34:5 | {...} | Foreach.cs:32:32:32:35 | access to parameter args | semmle.label | successor |
672+
| Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:33:11:33:11 | ; | semmle.label | non-empty |
673+
| Foreach.cs:32:32:32:35 | access to parameter args | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | semmle.label | successor |
674+
| Foreach.cs:33:11:33:11 | ; | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | semmle.label | successor |
675+
| Foreach.cs:37:5:40:5 | {...} | Foreach.cs:38:39:38:42 | access to parameter args | semmle.label | successor |
676+
| Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:39:11:39:11 | ; | semmle.label | non-empty |
677+
| Foreach.cs:38:39:38:42 | access to parameter args | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | semmle.label | successor |
678+
| Foreach.cs:39:11:39:11 | ; | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | semmle.label | successor |
667679
| Initializers.cs:9:5:12:5 | {...} | Initializers.cs:10:9:10:54 | ... ...; | semmle.label | successor |
668680
| Initializers.cs:10:9:10:54 | ... ...; | Initializers.cs:10:13:10:13 | access to local variable i | semmle.label | successor |
669681
| Initializers.cs:10:13:10:13 | access to local variable i | Initializers.cs:10:34:10:35 | "" | semmle.label | successor |

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

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -706,6 +706,27 @@
706706
| Foreach.cs:20:29:20:38 | call to method ToArray | Foreach.cs:20:27:20:27 | access to parameter e |
707707
| Foreach.cs:20:43:20:68 | call to method Empty | Foreach.cs:20:43:20:68 | call to method Empty |
708708
| Foreach.cs:21:11:21:11 | ; | Foreach.cs:21:11:21:11 | ; |
709+
| Foreach.cs:25:5:28:5 | {...} | Foreach.cs:25:5:28:5 | {...} |
710+
| Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:26:36:26:39 | access to parameter args |
711+
| Foreach.cs:26:18:26:31 | (..., ...) | Foreach.cs:26:23:26:23 | String x |
712+
| Foreach.cs:26:23:26:23 | String x | Foreach.cs:26:23:26:23 | String x |
713+
| Foreach.cs:26:30:26:30 | Int32 y | Foreach.cs:26:30:26:30 | Int32 y |
714+
| Foreach.cs:26:36:26:39 | access to parameter args | Foreach.cs:26:36:26:39 | access to parameter args |
715+
| Foreach.cs:27:11:27:11 | ; | Foreach.cs:27:11:27:11 | ; |
716+
| Foreach.cs:31:5:34:5 | {...} | Foreach.cs:31:5:34:5 | {...} |
717+
| Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:32:32:32:35 | access to parameter args |
718+
| Foreach.cs:32:18:32:27 | (..., ...) | Foreach.cs:32:23:32:23 | String x |
719+
| Foreach.cs:32:23:32:23 | String x | Foreach.cs:32:23:32:23 | String x |
720+
| Foreach.cs:32:26:32:26 | Int32 y | Foreach.cs:32:26:32:26 | Int32 y |
721+
| Foreach.cs:32:32:32:35 | access to parameter args | Foreach.cs:32:32:32:35 | access to parameter args |
722+
| Foreach.cs:33:11:33:11 | ; | Foreach.cs:33:11:33:11 | ; |
723+
| Foreach.cs:37:5:40:5 | {...} | Foreach.cs:37:5:40:5 | {...} |
724+
| Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:38:39:38:42 | access to parameter args |
725+
| Foreach.cs:38:18:38:34 | (..., ...) | Foreach.cs:38:26:38:26 | String x |
726+
| Foreach.cs:38:26:38:26 | String x | Foreach.cs:38:26:38:26 | String x |
727+
| Foreach.cs:38:33:38:33 | Int32 y | Foreach.cs:38:33:38:33 | Int32 y |
728+
| Foreach.cs:38:39:38:42 | access to parameter args | Foreach.cs:38:39:38:42 | access to parameter args |
729+
| Foreach.cs:39:11:39:11 | ; | Foreach.cs:39:11:39:11 | ; |
709730
| Initializers.cs:6:28:6:30 | {...} | Initializers.cs:6:28:6:30 | {...} |
710731
| Initializers.cs:9:5:12:5 | {...} | Initializers.cs:9:5:12:5 | {...} |
711732
| Initializers.cs:10:9:10:54 | ... ...; | Initializers.cs:10:9:10:54 | ... ...; |

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

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,9 @@
6262
| Foreach.cs:6:10:6:11 | M1 | Foreach.cs:7:5:10:5 | {...} |
6363
| Foreach.cs:12:10:12:11 | M2 | Foreach.cs:13:5:16:5 | {...} |
6464
| Foreach.cs:18:10:18:11 | M3 | Foreach.cs:19:5:22:5 | {...} |
65+
| Foreach.cs:24:10:24:11 | M4 | Foreach.cs:25:5:28:5 | {...} |
66+
| Foreach.cs:30:10:30:11 | M5 | Foreach.cs:31:5:34:5 | {...} |
67+
| Foreach.cs:36:10:36:11 | M6 | Foreach.cs:37:5:40:5 | {...} |
6568
| Initializers.cs:6:5:6:16 | Initializers | Initializers.cs:6:28:6:30 | {...} |
6669
| Initializers.cs:8:10:8:10 | M | Initializers.cs:9:5:12:5 | {...} |
6770
| NullCoalescing.cs:3:9:3:10 | M1 | NullCoalescing.cs:3:23:3:28 | ... ?? ... |

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

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -948,6 +948,27 @@
948948
| Foreach.cs:20:29:20:38 | call to method ToArray | Foreach.cs:20:29:20:38 | call to method ToArray | null |
949949
| Foreach.cs:20:43:20:68 | call to method Empty | Foreach.cs:20:43:20:68 | call to method Empty | normal |
950950
| Foreach.cs:21:11:21:11 | ; | Foreach.cs:21:11:21:11 | ; | normal |
951+
| Foreach.cs:25:5:28:5 | {...} | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | empty |
952+
| Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | Foreach.cs:26:9:27:11 | foreach (... ... in ...) ... | empty |
953+
| Foreach.cs:26:18:26:31 | (..., ...) | Foreach.cs:26:18:26:31 | (..., ...) | normal |
954+
| Foreach.cs:26:23:26:23 | String x | Foreach.cs:26:23:26:23 | String x | normal |
955+
| Foreach.cs:26:30:26:30 | Int32 y | Foreach.cs:26:30:26:30 | Int32 y | normal |
956+
| Foreach.cs:26:36:26:39 | access to parameter args | Foreach.cs:26:36:26:39 | access to parameter args | normal |
957+
| Foreach.cs:27:11:27:11 | ; | Foreach.cs:27:11:27:11 | ; | normal |
958+
| Foreach.cs:31:5:34:5 | {...} | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | empty |
959+
| Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | Foreach.cs:32:9:33:11 | foreach (... ... in ...) ... | empty |
960+
| Foreach.cs:32:18:32:27 | (..., ...) | Foreach.cs:32:18:32:27 | (..., ...) | normal |
961+
| Foreach.cs:32:23:32:23 | String x | Foreach.cs:32:23:32:23 | String x | normal |
962+
| Foreach.cs:32:26:32:26 | Int32 y | Foreach.cs:32:26:32:26 | Int32 y | normal |
963+
| Foreach.cs:32:32:32:35 | access to parameter args | Foreach.cs:32:32:32:35 | access to parameter args | normal |
964+
| Foreach.cs:33:11:33:11 | ; | Foreach.cs:33:11:33:11 | ; | normal |
965+
| Foreach.cs:37:5:40:5 | {...} | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | empty |
966+
| Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | Foreach.cs:38:9:39:11 | foreach (... ... in ...) ... | empty |
967+
| Foreach.cs:38:18:38:34 | (..., ...) | Foreach.cs:38:18:38:34 | (..., ...) | normal |
968+
| Foreach.cs:38:26:38:26 | String x | Foreach.cs:38:26:38:26 | String x | normal |
969+
| Foreach.cs:38:33:38:33 | Int32 y | Foreach.cs:38:33:38:33 | Int32 y | normal |
970+
| Foreach.cs:38:39:38:42 | access to parameter args | Foreach.cs:38:39:38:42 | access to parameter args | normal |
971+
| Foreach.cs:39:11:39:11 | ; | Foreach.cs:39:11:39:11 | ; | normal |
951972
| Initializers.cs:6:28:6:30 | {...} | Initializers.cs:6:28:6:30 | {...} | normal |
952973
| Initializers.cs:9:5:12:5 | {...} | Initializers.cs:11:13:11:63 | Initializers[] iz = ... | normal |
953974
| Initializers.cs:10:9:10:54 | ... ...; | Initializers.cs:10:13:10:53 | Initializers i = ... | normal |

0 commit comments

Comments
 (0)