9 lines
244 B
Text
9 lines
244 B
Text
|
==== tests/cases/compiler/switchAssignmentCompat.ts (1 errors) ====
|
||
|
class Foo { }
|
||
|
|
||
|
switch (0) {
|
||
|
case Foo: break; // Error expected
|
||
|
~~~
|
||
|
!!! Type 'typeof Foo' is not assignable to type 'number'.
|
||
|
}
|
||
|
|