mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
39 lines
825 B
TypeScript
39 lines
825 B
TypeScript
//// [tests/cases/compiler/anonymousClassDeclarationDoesntPrintWithReadonly.ts] ////
|
|
|
|
//// [anonymousClassDeclarationDoesntPrintWithReadonly.ts]
|
|
export class X {
|
|
constructor(readonly a: number) { }
|
|
}
|
|
|
|
export function y() {
|
|
return class extends X { }
|
|
}
|
|
|
|
//// [anonymousClassDeclarationDoesntPrintWithReadonly.js]
|
|
"use strict";
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
exports.X = void 0;
|
|
exports.y = y;
|
|
class X {
|
|
constructor(a) {
|
|
this.a = a;
|
|
}
|
|
}
|
|
exports.X = X;
|
|
function y() {
|
|
return class extends X {
|
|
};
|
|
}
|
|
|
|
|
|
//// [anonymousClassDeclarationDoesntPrintWithReadonly.d.ts]
|
|
export declare class X {
|
|
readonly a: number;
|
|
constructor(a: number);
|
|
}
|
|
export declare function y(): {
|
|
new (a: number): {
|
|
readonly a: number;
|
|
};
|
|
};
|