mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 06:05:01 +07:00
surround with: don't accept physical expression guessed from selection
This commit is contained in:
+1
-1
@@ -50,7 +50,7 @@ public class JavaExpressionSurroundDescriptor implements SurroundDescriptor {
|
||||
PsiExpression expr = CodeInsightUtil.findExpressionInRange(file, startOffset, endOffset);
|
||||
if (expr == null) {
|
||||
expr = IntroduceVariableBase.getSelectedExpression(file.getProject(), file, startOffset, endOffset);
|
||||
if (expr == null) {
|
||||
if (expr == null || expr.isPhysical()) {
|
||||
return PsiElement.EMPTY_ARRAY;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user