Fix tests
This commit is contained in:
parent
3f4395e95b
commit
b61356d935
|
@ -46,13 +46,13 @@ unittest
|
||||||
{
|
{
|
||||||
import analysis.config;
|
import analysis.config;
|
||||||
StaticAnalysisConfig sac;
|
StaticAnalysisConfig sac;
|
||||||
sac.logic_precedence_check = true;
|
sac.logical_precedence_check = true;
|
||||||
assertAnalyzerWarnings(q{
|
assertAnalyzerWarnings(q{
|
||||||
void testFish()
|
void testFish()
|
||||||
{
|
{
|
||||||
if (a && b || c) {} // [warn]:
|
if (a && b || c) {} // [warn]: Use parenthesis to clarify this expression.
|
||||||
if ((a && b) || c) {} // Good
|
if ((a && b) || c) {} // Good
|
||||||
if (b || c && d) {} // [warn]:
|
if (b || c && d) {} // [warn]: Use parenthesis to clarify this expression.
|
||||||
if (b || (c && d)) {} // Good
|
if (b || (c && d)) {} // Good
|
||||||
}
|
}
|
||||||
}c, sac);
|
}c, sac);
|
||||||
|
|
Loading…
Reference in New Issue