mirror of
https://github.com/vercel-labs/scriptc.git
synced 2026-10-27 06:43:19 +08:00
11 lines
431 B
TypeScript
11 lines
431 B
TypeScript
function privateBrand() { return class { #value = 1; has(other: object): boolean { return #value in other; } }; }
|
|
function selfName() { return class Local { copy() { return new Local(); } }; }
|
|
class Base {}
|
|
function derived() { return class extends Base {}; }
|
|
function generic() { return class { read<T>(value: T): T { return value; } }; }
|
|
privateBrand();
|
|
selfName();
|
|
derived();
|
|
generic();
|
|
// End of unsupported local-class forms.
|