136 lines
2.9 KiB
Plaintext
136 lines
2.9 KiB
Plaintext
=== tests/cases/conformance/jsdoc/declarations/jsDeclarationsClassMethod.js ===
|
|
function C1() {
|
|
>C1 : typeof C1
|
|
|
|
/**
|
|
* A comment prop
|
|
* @param {number} x
|
|
* @param {number} y
|
|
* @returns {number}
|
|
*/
|
|
this.prop = function (x, y) {
|
|
>this.prop = function (x, y) { return x + y; } : (x: number, y: number) => number
|
|
>this.prop : any
|
|
>this : this
|
|
>prop : any
|
|
>function (x, y) { return x + y; } : (x: number, y: number) => number
|
|
>x : number
|
|
>y : number
|
|
|
|
return x + y;
|
|
>x + y : number
|
|
>x : number
|
|
>y : number
|
|
}
|
|
}
|
|
|
|
/**
|
|
* A comment method
|
|
* @param {number} x
|
|
* @param {number} y
|
|
* @returns {number}
|
|
*/
|
|
C1.prototype.method = function (x, y) {
|
|
>C1.prototype.method = function (x, y) { return x + y;} : (x: number, y: number) => number
|
|
>C1.prototype.method : any
|
|
>C1.prototype : any
|
|
>C1 : typeof C1
|
|
>prototype : any
|
|
>method : any
|
|
>function (x, y) { return x + y;} : (x: number, y: number) => number
|
|
>x : number
|
|
>y : number
|
|
|
|
return x + y;
|
|
>x + y : number
|
|
>x : number
|
|
>y : number
|
|
}
|
|
|
|
/**
|
|
* A comment staticProp
|
|
* @param {number} x
|
|
* @param {number} y
|
|
* @returns {number}
|
|
*/
|
|
C1.staticProp = function (x, y) {
|
|
>C1.staticProp = function (x, y) { return x + y;} : (x: number, y: number) => number
|
|
>C1.staticProp : (x: number, y: number) => number
|
|
>C1 : typeof C1
|
|
>staticProp : (x: number, y: number) => number
|
|
>function (x, y) { return x + y;} : (x: number, y: number) => number
|
|
>x : number
|
|
>y : number
|
|
|
|
return x + y;
|
|
>x + y : number
|
|
>x : number
|
|
>y : number
|
|
}
|
|
|
|
class C2 {
|
|
>C2 : C2
|
|
|
|
/**
|
|
* A comment method1
|
|
* @param {number} x
|
|
* @param {number} y
|
|
* @returns {number}
|
|
*/
|
|
method1(x, y) {
|
|
>method1 : (x: number, y: number) => number
|
|
>x : number
|
|
>y : number
|
|
|
|
return x + y;
|
|
>x + y : number
|
|
>x : number
|
|
>y : number
|
|
}
|
|
}
|
|
|
|
/**
|
|
* A comment method2
|
|
* @param {number} x
|
|
* @param {number} y
|
|
* @returns {number}
|
|
*/
|
|
C2.prototype.method2 = function (x, y) {
|
|
>C2.prototype.method2 = function (x, y) { return x + y;} : (x: number, y: number) => number
|
|
>C2.prototype.method2 : (x: number, y: number) => number
|
|
>C2.prototype : C2
|
|
>C2 : typeof C2
|
|
>prototype : C2
|
|
>method2 : (x: number, y: number) => number
|
|
>function (x, y) { return x + y;} : (x: number, y: number) => number
|
|
>x : number
|
|
>y : number
|
|
|
|
return x + y;
|
|
>x + y : number
|
|
>x : number
|
|
>y : number
|
|
}
|
|
|
|
/**
|
|
* A comment staticProp
|
|
* @param {number} x
|
|
* @param {number} y
|
|
* @returns {number}
|
|
*/
|
|
C2.staticProp = function (x, y) {
|
|
>C2.staticProp = function (x, y) { return x + y;} : (x: number, y: number) => number
|
|
>C2.staticProp : (x: number, y: number) => number
|
|
>C2 : typeof C2
|
|
>staticProp : (x: number, y: number) => number
|
|
>function (x, y) { return x + y;} : (x: number, y: number) => number
|
|
>x : number
|
|
>y : number
|
|
|
|
return x + y;
|
|
>x + y : number
|
|
>x : number
|
|
>y : number
|
|
}
|
|
|