Annotations in PHPDoc should be ordered so that @param
annotations come
first, then @throws
annotations, then @return
annotations.
--- Original
+++ New
@@ -2,9 +2,9 @@
/**
* Hello there!
*
- * @throws Exception|RuntimeException foo
* @custom Test!
- * @return int Return the number of changes.
* @param string $foo
* @param bool $bar Bar
+ * @throws Exception|RuntimeException foo
+ * @return int Return the number of changes.
*/
The rule is part of the following rule set:
- @PhpCsFixer
- Using the @PhpCsFixer rule set will enable the
phpdoc_order
rule.