Skip to content

Commit

Permalink
ASTDiff: Fixes #836
Browse files Browse the repository at this point in the history
  • Loading branch information
pouryafard75 authored and tsantalis committed Dec 29, 2024
1 parent e8943b4 commit 3312bde
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -235,12 +235,14 @@ private void processRefactorings(Tree srcTree, Tree dstTree, List<Refactoring> r
break;
case PARAMETERIZE_VARIABLE:
eligible = !renameVariableRefactoring.isInsideExtractedOrInlinedMethod();

if (!eligible)
break;
while (!TreeUtilFunctions.isStatement(srcInput.getType().name)) {
while (srcInput != null && !TreeUtilFunctions.isStatement(srcInput.getType().name)) {
if (srcInput.getType() == null) break;
srcInput = srcInput.getParent();
}
if (srcInput == null) return;
if (TreeUtilFunctions.isStatement(srcInput.getType().name)){
new LeafMatcher().match(srcInput,dstInput,mappingStore);
}
Expand Down

0 comments on commit 3312bde

Please sign in to comment.