Home
last modified time | relevance | path

Searched refs:replaceNode (Results 1 – 25 of 57) sorted by relevance

123

/third_party/typescript/src/services/refactors/
DconvertExport.ts127 …changes.replaceNode(exportingSourceFile, exportNode, factory.createExportDeclaration(/*modifiers*/…
146 …changes.replaceNode(exportingSourceFile, exportNode, factory.createExportDefault(Debug.checkDefine…
183 changes.replaceNode(importingSourceFile, ref, factory.createIdentifier(exportName));
189 … changes.replaceNode(importingSourceFile, spec, makeImportSpecifier(exportName, spec.name.text));
199 … changes.replaceNode(importingSourceFile, ref, factory.createNamedImports([spec]));
217 …changes.replaceNode(importingSourceFile, parent, factory.createImportTypeNode(importTypeNode.argum…
229 changes.replaceNode(importingSourceFile, ref, factory.createIdentifier("default"));
236 changes.replaceNode(importingSourceFile, parent.parent, defaultImport);
249 …changes.replaceNode(importingSourceFile, parent, makeExportSpecifier("default", parent.name.text));
DconvertImport.ts133 …changes.replaceNode(sourceFile, propertyAccessOrQualifiedName, factory.createIdentifier(importName…
147 …changes.replaceNode(sourceFile, importDecl, updateImport(importDecl, usedAsNamespaceOrDefault ? fa…
200 … changes.replaceNode(sourceFile, id.parent, factory.createPropertyAssignment(id.text, access));
206 changes.replaceNode(sourceFile, id, access);
211 changes.replaceNode(sourceFile, toConvert, shouldUseDefault
DconvertArrowFunctionOrFunctionExpression.ts207 return textChanges.ChangeTracker.with(context, t => t.replaceNode(file, func, newNode));
222 … return textChanges.ChangeTracker.with(context, t => t.replaceNode(file, statement, newNode));
248 return textChanges.ChangeTracker.with(context, t => t.replaceNode(file, func, newNode));
DextractType.ts209 …changes.replaceNode(file, selection, factory.createTypeReferenceNode(name, typeParameters.map(id =…
224 …changes.replaceNode(file, selection, factory.createTypeReferenceNode(name, typeParameters.map(id =…
250 …changes.replaceNode(file, selection, factory.createTypeReferenceNode(name, typeParameters.map(id =…
/third_party/typescript/src/services/codefixes/
DconvertToEsModule.ts30 …changes.replaceNode(importingFile, importNode, makeImport(importNode.name, /*namedImports*/ undefi…
34 …changes.replaceNode(importingFile, importNode, factory.createPropertyAccessExpression(getSynthesiz…
62 changes.replaceNode(sourceFile, original, replacement);
98 … changes.replaceNode(sourceFile, node, factory.createIdentifier(exports.get(text) || text));
136 …changes.replaceNode(sourceFile, statement, makeImport(/*name*/ undefined, /*namedImports*/ undefin…
379 … ? getSynthesizedDeepClonesWithReplacements(nodeOrNodes, /*includeTrivia*/ true, replaceNode)
380 … : getSynthesizedDeepCloneWithReplacements(nodeOrNodes, /*includeTrivia*/ true, replaceNode);
382 function replaceNode(original: Node) {
DaddMissingAwait.ts234 …changeTracker.replaceNode(sourceFile, forOf, factory.updateForOfStatement(forOf, factory.createTok…
248 changeTracker.replaceNode(sourceFile, side, newNode);
258 changeTracker.replaceNode(
271 …changeTracker.replaceNode(sourceFile, insertionSite, factory.createParenthesizedExpression(factory…
281 …changeTracker.replaceNode(sourceFile, insertionSite, factory.createAwaitExpression(insertionSite));
DfixStrictClassInitialization.ts79 changeTracker.replaceNode(propertyDeclarationSourceFile, propertyDeclaration, property);
95 changeTracker.replaceNode(sourceFile, info.type, unionTypeNode);
120 changeTracker.replaceNode(propertyDeclarationSourceFile, propertyDeclaration, property);
DfixSpelling.ts108 changes.replaceNode(sourceFile, node, factory.createIdentifier(suggestion));
111 …changes.replaceNode(sourceFile, node.parent, factory.createElementAccessExpression(node.parent.exp…
115 changes.replaceNode(sourceFile, node, factory.createIdentifier(suggestion));
DgenerateAccessors.ts194 changeTracker.replaceNode(file, declaration, property);
210 changeTracker.replaceNode(file, declaration,
229 … changeTracker.replaceNode(file, node.argumentExpression, factory.createStringLiteral(fieldName));
232 changeTracker.replaceNode(file, node.name, factory.createIdentifier(fieldName));
DfixInvalidImportSyntax.ts28 …const changes = textChanges.ChangeTracker.with(context, t => t.replaceNode(sourceFile, node, repla…
90 …const changes = textChanges.ChangeTracker.with(context, t => t.replaceNode(sourceFile, expr, facto…
DreturnValueCorrect.ts210 changes.replaceNode(sourceFile, statement, factory.createReturnStatement(expression), {
222 changes.replaceNode(sourceFile, declaration.body, newBody);
226 …changes.replaceNode(sourceFile, declaration.body, factory.createParenthesizedExpression(expression…
DuseBigintLiteral.ts31 changeTracker.replaceNode(sourceFile, numericLiteral, factory.createBigIntLiteral(newText));
DaddMissingInvocationForDecorator.ts20 changeTracker.replaceNode(sourceFile, decorator.expression, replacement);
DfixPropertyAssignment.ts22 …changes.replaceNode(sourceFile, node, factory.createPropertyAssignment(node.name, node.objectAssig…
DfixAddMissingNewOperator.ts21 changes.replaceNode(sourceFile, call, newExpression);
DremoveUnnecessaryAwait.ts41 changeTracker.replaceNode(sourceFile, expressionToReplace, awaitExpression.expression);
DaddNameToNamelessParameter.ts34 changeTracker.replaceNode(sourceFile, param, replacement);
DfixAddModuleReferTypeMissingTypeof.ts29 changes.replaceNode(sourceFile, importType, newTypeNode);
DfixExpectedComma.ts44 changes.replaceNode(sourceFile, node, newNode);
DfixNoPropertyAccessFromIndexSignature.ts24 changes.replaceNode(
DsplitTypeOnlyImport.ts30 changes.replaceNode(context.sourceFile, importDeclaration, factory.updateImportDeclaration(
DcorrectQualifiedNameToIndexedAccessType.ts34 changeTracker.replaceNode(sourceFile, qualifiedName, replacement);
DaddConvertToUnknownForNonOverlappingTypes.ts26 changeTracker.replaceNode(sourceFile, assertion.expression, replacement);
DconvertLiteralTypeToMappedType.ts50 changes.replaceNode(sourceFile, container, factory.createMappedTypeNode(
/third_party/typescript/src/testRunner/unittests/services/
DtextChanges.ts237 changeTracker.replaceNode(sourceFile, findChild("y", sourceFile), newNode);
250 …changeTracker.replaceNode(sourceFile, findVariableStatementContaining("y", sourceFile), createTest…
253 …changeTracker.replaceNode(sourceFile, findVariableStatementContaining("y", sourceFile), createTest…
256 …changeTracker.replaceNode(sourceFile, findVariableStatementContaining("y", sourceFile), createTest…
259 …changeTracker.replaceNode(sourceFile, findVariableStatementContaining("y", sourceFile), createTest…
262 …changeTracker.replaceNode(sourceFile, findVariableStatementContaining("x", sourceFile), createTest…

123