@Nullable
  private <T extends PsiExpression> T getExpression(@NotNull Class<T> aClass, @NotNull PsiExpression patternExpression) {
    PsiExpression expression = myMatchingVisitor.getElement(PsiExpression.class);
    if (!(patternExpression.getParent() instanceof PsiExpressionStatement)) {
      expression = PsiUtil.skipParenthesizedExprDown(expression);
    }
    return myMatchingVisitor.setResult(aClass.isInstance(expression)) ? aClass.cast(expression) : null;
  }
@Nullable
  private <T extends PsiExpression> T getExpression(@NotNull Class<T> aClass, @NotNull PsiExpression patternExpression)