Skip to content

Commit dc5bced

Browse files
committed
PHPCS: add some extra function comment rules
1 parent b6e8853 commit dc5bced

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

phpcs.xml.dist

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,4 +182,17 @@
182182
<!-- Prevent conflict with function spacing sniff. -->
183183
<exclude-pattern>/requirements\.php</exclude-pattern>
184184
</rule>
185+
186+
<!-- Use select error codes from the Squiz FunctionComment sniff, which shouldn't conflict with the PEAR sniff. -->
187+
<rule ref="Squiz.Commenting.FunctionComment.InvalidReturnVoid"/>
188+
<rule ref="Squiz.Commenting.FunctionComment.InvalidNoReturn"/>
189+
<rule ref="Squiz.Commenting.FunctionComment.InvalidReturnNotVoid"/>
190+
<rule ref="Squiz.Commenting.FunctionComment.ThrowsNotCapital"/>
191+
<rule ref="Squiz.Commenting.FunctionComment.ThrowsNoFullStop"/>
192+
<rule ref="Squiz.Commenting.FunctionComment.InvalidReturnVoid"/>
193+
<rule ref="Squiz.Commenting.FunctionComment.IncorrectTypeHint"/>
194+
<rule ref="Squiz.Commenting.FunctionComment.InvalidTypeHint"/>
195+
<rule ref="Squiz.Commenting.FunctionComment.ParamNameUnexpectedAmpersandPrefix"/>
196+
<rule ref="Squiz.Commenting.FunctionComment.ParamCommentNotCapital"/>
197+
185198
</ruleset>

0 commit comments

Comments
 (0)