.. _dump-dumpcomparedliterals: .. _collect-compared-literals: Collect Compared Literals +++++++++++++++++++++++++ This collects the different literals (null, integers, floats, strings) that are used in comparisons. Comparisons include all the comparison operators : <, >, <=, >=, !=, <>, ==. This analysis also covers `switch() `_, `array_keys() `_ and `in_array() `_. Strict searches are omitted. So, ===, !==, `match() `_, `in_array() `_ and `array_keys() `_ with 3rd parameter are omitted. Some comparisons are not covered yet : `sort() `_. .. code-block:: php ' and 3 if ($x > 3) { // doSomething() } ?> Specs _____ +--------------+-------------------------------------------------------------------------------------------------------------------------+ | Short name | Dump/DumpComparedLiterals | +--------------+-------------------------------------------------------------------------------------------------------------------------+ | Rulesets | :ref:`All `, :ref:`Changed Behavior `, :ref:`Dump ` | +--------------+-------------------------------------------------------------------------------------------------------------------------+ | Exakat since | 2.5.3 | +--------------+-------------------------------------------------------------------------------------------------------------------------+ | PHP Version | All | +--------------+-------------------------------------------------------------------------------------------------------------------------+ | Severity | Minor | +--------------+-------------------------------------------------------------------------------------------------------------------------+ | Time To Fix | Quick (30 mins) | +--------------+-------------------------------------------------------------------------------------------------------------------------+ | Precision | High | +--------------+-------------------------------------------------------------------------------------------------------------------------+ | Available in | `Entreprise Edition `_, `Exakat Cloud `_ | +--------------+-------------------------------------------------------------------------------------------------------------------------+