mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
39 lines
1.2 KiB
TypeScript
39 lines
1.2 KiB
TypeScript
//// [tests/cases/compiler/controlFlowForCompoundAssignmentToThisMember.ts] ////
|
|
|
|
//// [controlFlowForCompoundAssignmentToThisMember.ts]
|
|
class DatasourceCommandWidgetElement {
|
|
_commandBased: boolean;
|
|
_commandElement: unknown;
|
|
commandElement: unknown;
|
|
|
|
constructor(target: unknown) {
|
|
if (target instanceof DatasourceCommandWidgetElement) {
|
|
this._commandBased = true;
|
|
this._commandElement = target.commandElement;
|
|
} else {
|
|
this._commandBased = false;
|
|
}
|
|
|
|
if (this._commandBased = (target instanceof DatasourceCommandWidgetElement)) {
|
|
this._commandElement = target.commandElement;
|
|
}
|
|
}
|
|
}
|
|
|
|
//// [controlFlowForCompoundAssignmentToThisMember.js]
|
|
"use strict";
|
|
class DatasourceCommandWidgetElement {
|
|
constructor(target) {
|
|
if (target instanceof DatasourceCommandWidgetElement) {
|
|
this._commandBased = true;
|
|
this._commandElement = target.commandElement;
|
|
}
|
|
else {
|
|
this._commandBased = false;
|
|
}
|
|
if (this._commandBased = (target instanceof DatasourceCommandWidgetElement)) {
|
|
this._commandElement = target.commandElement;
|
|
}
|
|
}
|
|
}
|