-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Labels
enhancementNew feature or requestNew feature or request
Description
input.ts:
export class Class {
private privateField: string = 'string-value';
public constructor() {
const that = this;
that[Math.random() ? 'privateMethod' : 'publicMethod'](this.privateField);
this[Math.random() ? 'privateMethod' : 'publicMethod'](this.privateField);
}
public publicMethod(): void {
}
private privateMethod(a: string): void {
}
}output.js:
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var Class = /** @class */ (function () {
function Class() {
this._private_privateField = 'string-value';
var that = this;
that[Math.random() ? '_private_privateMethod' : 'publicMethod'](this._private_privateField);
this[Math.random() ? '_private_privateMethod' : 'publicMethod'](this._private_privateField);
}
Class.prototype.publicMethod = function () {
};
Class.prototype._private_privateMethod = function (a) {
};
return Class;
}());
exports.Class = Class;or fail with error
shiweiwei97
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request