mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
76 lines
3.7 KiB
Plaintext
76 lines
3.7 KiB
Plaintext
//// [tests/cases/compiler/declarationEmitLocalClassDeclarationMixin.ts] ////
|
|
|
|
=== declarationEmitLocalClassDeclarationMixin.ts ===
|
|
interface Constructor<C> { new (...args: any[]): C; }
|
|
>Constructor : Symbol(Constructor, Decl(declarationEmitLocalClassDeclarationMixin.ts, 0, 0))
|
|
>C : Symbol(C, Decl(declarationEmitLocalClassDeclarationMixin.ts, 0, 22))
|
|
>args : Symbol(args, Decl(declarationEmitLocalClassDeclarationMixin.ts, 0, 32))
|
|
>C : Symbol(C, Decl(declarationEmitLocalClassDeclarationMixin.ts, 0, 22))
|
|
|
|
function mixin<B extends Constructor<{}>>(Base: B) {
|
|
>mixin : Symbol(mixin, Decl(declarationEmitLocalClassDeclarationMixin.ts, 0, 53))
|
|
>B : Symbol(B, Decl(declarationEmitLocalClassDeclarationMixin.ts, 2, 15))
|
|
>Constructor : Symbol(Constructor, Decl(declarationEmitLocalClassDeclarationMixin.ts, 0, 0))
|
|
>Base : Symbol(Base, Decl(declarationEmitLocalClassDeclarationMixin.ts, 2, 42))
|
|
>B : Symbol(B, Decl(declarationEmitLocalClassDeclarationMixin.ts, 2, 15))
|
|
|
|
class PrivateMixed extends Base {
|
|
>PrivateMixed : Symbol(PrivateMixed, Decl(declarationEmitLocalClassDeclarationMixin.ts, 2, 52))
|
|
>Base : Symbol(Base, Decl(declarationEmitLocalClassDeclarationMixin.ts, 2, 42))
|
|
|
|
bar = 2;
|
|
>bar : Symbol(PrivateMixed.bar, Decl(declarationEmitLocalClassDeclarationMixin.ts, 3, 37))
|
|
}
|
|
return PrivateMixed;
|
|
>PrivateMixed : Symbol(PrivateMixed, Decl(declarationEmitLocalClassDeclarationMixin.ts, 2, 52))
|
|
}
|
|
|
|
export class Unmixed {
|
|
>Unmixed : Symbol(Unmixed, Decl(declarationEmitLocalClassDeclarationMixin.ts, 7, 1))
|
|
|
|
foo = 1;
|
|
>foo : Symbol(Unmixed.foo, Decl(declarationEmitLocalClassDeclarationMixin.ts, 9, 22))
|
|
}
|
|
|
|
export const Mixed = mixin(Unmixed);
|
|
>Mixed : Symbol(Mixed, Decl(declarationEmitLocalClassDeclarationMixin.ts, 13, 12))
|
|
>mixin : Symbol(mixin, Decl(declarationEmitLocalClassDeclarationMixin.ts, 0, 53))
|
|
>Unmixed : Symbol(Unmixed, Decl(declarationEmitLocalClassDeclarationMixin.ts, 7, 1))
|
|
|
|
function Filter<C extends Constructor<{}>>(ctor: C) {
|
|
>Filter : Symbol(Filter, Decl(declarationEmitLocalClassDeclarationMixin.ts, 13, 36))
|
|
>C : Symbol(C, Decl(declarationEmitLocalClassDeclarationMixin.ts, 15, 16))
|
|
>Constructor : Symbol(Constructor, Decl(declarationEmitLocalClassDeclarationMixin.ts, 0, 0))
|
|
>ctor : Symbol(ctor, Decl(declarationEmitLocalClassDeclarationMixin.ts, 15, 43))
|
|
>C : Symbol(C, Decl(declarationEmitLocalClassDeclarationMixin.ts, 15, 16))
|
|
|
|
abstract class FilterMixin extends ctor {
|
|
>FilterMixin : Symbol(FilterMixin, Decl(declarationEmitLocalClassDeclarationMixin.ts, 15, 53))
|
|
>ctor : Symbol(ctor, Decl(declarationEmitLocalClassDeclarationMixin.ts, 15, 43))
|
|
|
|
abstract match(path: string): boolean;
|
|
>match : Symbol(FilterMixin.match, Decl(declarationEmitLocalClassDeclarationMixin.ts, 16, 45))
|
|
>path : Symbol(path, Decl(declarationEmitLocalClassDeclarationMixin.ts, 17, 23))
|
|
|
|
// other concrete methods, fields, constructor
|
|
thing = 12;
|
|
>thing : Symbol(FilterMixin.thing, Decl(declarationEmitLocalClassDeclarationMixin.ts, 17, 46))
|
|
}
|
|
return FilterMixin;
|
|
>FilterMixin : Symbol(FilterMixin, Decl(declarationEmitLocalClassDeclarationMixin.ts, 15, 53))
|
|
}
|
|
|
|
export class FilteredThing extends Filter(Unmixed) {
|
|
>FilteredThing : Symbol(FilteredThing, Decl(declarationEmitLocalClassDeclarationMixin.ts, 22, 1))
|
|
>Filter : Symbol(Filter, Decl(declarationEmitLocalClassDeclarationMixin.ts, 13, 36))
|
|
>Unmixed : Symbol(Unmixed, Decl(declarationEmitLocalClassDeclarationMixin.ts, 7, 1))
|
|
|
|
match(path: string) {
|
|
>match : Symbol(FilteredThing.match, Decl(declarationEmitLocalClassDeclarationMixin.ts, 24, 52))
|
|
>path : Symbol(path, Decl(declarationEmitLocalClassDeclarationMixin.ts, 25, 10))
|
|
|
|
return false;
|
|
}
|
|
}
|
|
|