rspec/rules/S1125/apex/rule.adoc

38 lines
608 B
Plaintext
Raw Normal View History

== Why is this an issue?
include::../description.adoc[]
=== Noncompliant code example
2022-02-04 17:28:24 +01:00
[source,apex]
----
if (booleanMethod() || false) { /* ... */ }
doSomething(!false);
doSomething(booleanMethod() && true);
----
=== Compliant solution
2022-02-04 17:28:24 +01:00
[source,apex]
----
if (booleanMethod()) { /* ... */ }
doSomething(true);
doSomething(booleanMethod());
----
ifdef::env-github,rspecator-view[]
'''
== Implementation Specification
(visible only on this page)
include::../message.adoc[]
'''
== Comments And Links
(visible only on this page)
include::../comments-and-links.adoc[]
endif::env-github,rspecator-view[]