mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
20 lines
391 B
TypeScript
20 lines
391 B
TypeScript
//// [tests/cases/conformance/expressions/optionalChaining/callChain/thisMethodCall.ts] ////
|
|
|
|
//// [thisMethodCall.ts]
|
|
class C {
|
|
method?() {}
|
|
other() {
|
|
this.method?.();
|
|
}
|
|
}
|
|
|
|
//// [thisMethodCall.js]
|
|
"use strict";
|
|
class C {
|
|
method() { }
|
|
other() {
|
|
var _a;
|
|
(_a = this.method) === null || _a === void 0 ? void 0 : _a.call(this);
|
|
}
|
|
}
|