mirror of
https://github.com/dlang/dmd.git
synced 2025-04-26 05:00:16 +03:00
17 lines
256 B
D
17 lines
256 B
D
/*
|
|
TEST_OUTPUT:
|
|
---
|
|
fail_compilation/issue11070.d(16): Error: undefined identifier `x`
|
|
---
|
|
*/
|
|
|
|
int get() { return 1; }
|
|
|
|
void test() {
|
|
import std.stdio : writeln;
|
|
switch (auto x = get()) {
|
|
default:
|
|
auto z = x;
|
|
}
|
|
x = 1;
|
|
}
|