mirror of
https://github.com/swc-project/swc.git
synced 2024-11-28 11:13:43 +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;
|
|
}
|
|
}
|