boolean (PsiExpression lhs, PsiExpression rhs, boolean formatCall) { @NonNls final String lhsLiteral = computeStringValue(lhs); if (lhsLiteral != null) { final int length = lhsLiteral.length(); if (length == 0 || formatCall && lhsLiteral.endsWith("%n")) { return false; } final char c = lhsLiteral.charAt(length - 1); if (Character.isWhitespace(c) || !Character.isLetterOrDigit(c)) { return false; } } else if (ignoreNonStringLiterals && ExpressionUtils.hasStringType(lhs)) { return false; } @NonNls final String rhsLiteral = computeStringValue(rhs); if (rhsLiteral != null) { if (rhsLiteral.isEmpty() || formatCall && rhsLiteral.startsWith("%n")) { return false; } final char c = rhsLiteral.charAt(0); if (Character.isWhitespace(c) || !Character.isLetterOrDigit(c)) { return false; } } else if (ignoreNonStringLiterals && ExpressionUtils.hasStringType(rhs)) { return false; } return true; }