mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-14 18:05:27 +07:00
GroovyBreak GroovyConditional GroovyConditionalCanBeConditionalCall GroovyConditionalCanBeElvis GroovyConditionalWithIdenticalBranches GroovyContinue GroovyContinueOrBreakFromFinallyBlock GrEqualsBetweenInconvertibleTypes GrFinalVariableAccess GrMethodMayBeStatic GrNamedVariantLabels GroovyAccessibility GitOrigin-RevId: 7e8b924a88f98e61918478174810bb4fe50cc9ed
15 lines
384 B
HTML
15 lines
384 B
HTML
<html>
|
|
<body>
|
|
Reports ternary expressions with identical "then" and "else" branches. Such expressions are almost certainly a programmer error.
|
|
<p>The quick-fix replaces the expression with its "then" branch.</p>
|
|
<p><b>Example:</b></p>
|
|
<pre><code>
|
|
condition ? a.foo() : a.foo()
|
|
</code></pre>
|
|
<p>After the quick-fix is applied:</p>
|
|
<pre><code>
|
|
a.foo()
|
|
</code></pre>
|
|
</body>
|
|
</html>
|