include::../description.adoc[]

== Noncompliant Code Example

----
if ($booleanVariable == true) { /* ... */ }      
if ($booleanVariable != true) { /* ... */ }   
if ($booleanVariable || false) { /* ... */ }     
doSomething(!false);
----

== Compliant Solution

----
if ($booleanVariable) { /* ... */ }              
if (!$booleanVariable) { /* ... */ }    
if ($booleanVariable) { /* ... */ }       
doSomething(true);
----

== Exceptions

The use of literal booleans in comparisons which use identity operators (``++===++`` and ``++!==++``) are ignored.

ifdef::env-github,rspecator-view[]
'''
== Comments And Links
(visible only on this page)

include::comments-and-links.adoc[]
endif::env-github,rspecator-view[]
