mirror of
https://github.com/swc-project/swc.git
synced 2024-12-18 19:21:33 +03:00
14 lines
293 B
TypeScript
14 lines
293 B
TypeScript
// @strict: true
|
|
// @noUnusedLocals: true
|
|
// @target: esnext, es2022
|
|
|
|
class Foo {
|
|
#unused: undefined; // expect unused error
|
|
#brand: undefined; // expect no error
|
|
|
|
isFoo(v: any): v is Foo {
|
|
// This should count as using/reading '#brand'
|
|
return #brand in v;
|
|
}
|
|
}
|