================================== Rule ``single_line_comment_style`` ================================== Single-line comments and multi-line comments with only one line of actual content should use the ``//`` syntax. Configuration ------------- ``comment_types`` ~~~~~~~~~~~~~~~~~ List of comment types to fix. Allowed values: a subset of ``['asterisk', 'hash']`` Default value: ``['asterisk', 'hash']`` Examples -------- Example #1 ~~~~~~~~~~ *Default* configuration. .. code-block:: diff --- Original +++ New ['asterisk']]``. .. code-block:: diff --- Original +++ New ['hash']]``. .. code-block:: diff --- Original +++ New -`_ - `@Symfony <./../../ruleSets/Symfony.rst>`_ with config: ``['comment_types' => ['hash']]`` References ---------- - Fixer class: `PhpCsFixer\\Fixer\\Comment\\SingleLineCommentStyleFixer <./../../../src/Fixer/Comment/SingleLineCommentStyleFixer.php>`_ - Test class: `PhpCsFixer\\Tests\\Fixer\\Comment\\SingleLineCommentStyleFixerTest <./../../../tests/Fixer/Comment/SingleLineCommentStyleFixerTest.php>`_ The test class defines officially supported behaviour. Each test case is a part of our backward compatibility promise.