mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
fix parenthesis expr during precise rethrow detection
This commit is contained in:
@@ -579,7 +579,8 @@ public class ExceptionUtil {
|
||||
}
|
||||
|
||||
@NotNull
|
||||
private static List<PsiType> getPreciseThrowTypes(@Nullable final PsiExpression expression) {
|
||||
private static List<PsiType> getPreciseThrowTypes(@Nullable PsiExpression expression) {
|
||||
expression = PsiUtil.skipParenthesizedExprDown(expression);
|
||||
if (expression instanceof PsiReferenceExpression) {
|
||||
final PsiElement target = ((PsiReferenceExpression)expression).resolve();
|
||||
if (target != null && PsiUtil.isCatchParameter(target)) {
|
||||
|
||||
+8
@@ -193,6 +193,14 @@ class C {
|
||||
}
|
||||
}
|
||||
|
||||
void m11_5() {
|
||||
try {}
|
||||
catch (Exception e) {
|
||||
//parentesis expr
|
||||
throw (e);
|
||||
}
|
||||
}
|
||||
|
||||
static class MyResource implements AutoCloseable {
|
||||
public void close() throws E1 { }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user