mirror of
https://github.com/swc-project/swc.git
synced 2024-12-24 22:22:34 +03:00
22 lines
226 B
TypeScript
22 lines
226 B
TypeScript
|
interface Boolean {
|
||
|
doStuff(): string;
|
||
|
}
|
||
|
|
||
|
interface NotBoolean {
|
||
|
doStuff(): string;
|
||
|
}
|
||
|
|
||
|
var x = true;
|
||
|
var a: Boolean;
|
||
|
var b: NotBoolean;
|
||
|
|
||
|
a = x;
|
||
|
a = b;
|
||
|
|
||
|
b = a;
|
||
|
b = x;
|
||
|
|
||
|
x = a; // expected error
|
||
|
x = b; // expected error
|
||
|
|