remove getRawObject

Signed-off-by: houhaoyu <houhaoyu@huawei.com>
Change-Id: I69f3b4e90682c8a5118d9c1a18d178e3b4a905f5
This commit is contained in:
houhaoyu
2022-06-25 15:59:59 +08:00
parent d145684fa1
commit 37c8c3b41c
-8
View File
@@ -332,14 +332,6 @@ function processBuildMember(node: ts.MethodDeclaration, context: ts.Transformati
if (isProperty(node)) {
node = createReference(node as ts.PropertyAssignment, log);
}
if (ts.isPropertyAccessExpression(node) && ts.isIdentifier(node.name) &&
stateObjectCollection.has(node.name.escapedText.toString()) && node.parent &&
ts.isCallExpression(node.parent) && ts.isPropertyAccessExpression(node.parent.expression) &&
node.parent.expression.name.escapedText.toString() !== FOREACH_GET_RAW_OBJECT) {
return ts.factory.createCallExpression(ts.factory.createPropertyAccessExpression(
ts.factory.createIdentifier(FOREACH_OBSERVED_OBJECT),
ts.factory.createIdentifier(FOREACH_GET_RAW_OBJECT)), undefined, [node]);
}
return ts.visitEachChild(node, visitBuild, context);
}
}