mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
34 lines
465 B
TypeScript
34 lines
465 B
TypeScript
//// [tests/cases/compiler/argumentsReferenceInConstructor2_Js.ts] ////
|
|
|
|
//// [a.js]
|
|
class A {
|
|
/**
|
|
* Constructor
|
|
*
|
|
* @param {object} [foo={}]
|
|
*/
|
|
constructor(foo = {}) {
|
|
/**
|
|
* @type object
|
|
*/
|
|
this["arguments"] = foo;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
//// [a.d.ts]
|
|
declare class A {
|
|
/**
|
|
* @type object
|
|
*/
|
|
"arguments": object;
|
|
/**
|
|
* Constructor
|
|
*
|
|
* @param {object} [foo={}]
|
|
*/
|
|
constructor(foo?: object);
|
|
}
|