mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-09 21:08:53 +00:00
Merge branch 'develop-ascraeus' into develop
* develop-ascraeus: [ticket/12721] Update rules descriptions [ticket/12721] Add Generic.NamingConventions.ConstructorName in strict [ticket/12721] Add Squiz.Functions.LowercaseFunctionKeywords in legacy [ticket/12721] Add Squiz.ControlStructures.ForLoopDeclaration in legacy [ticket/12721] Add Squiz.ControlStructures.ForEachLoopDeclaration [ticket/12721] Add Squiz.ControlStructures.ElseIfDeclaration in legacy [ticket/12721] Add Generic.Functions.OpeningFunctionBraceBsdAllman [ticket/12721] Add Squiz.Arrays.ArrayBracketSpacing in the legacy ruleset [ticket/12721] Add Generic.Files.LowercasedFilename in the legacy ruleset
This commit is contained in:
commit
c9da435d3c
15 changed files with 45 additions and 17 deletions
|
@ -20,6 +20,13 @@
|
|||
<!-- Call-time pass-by-reference MUST not be used. -->
|
||||
<rule ref="Generic.Functions.CallTimePassByReference.NotAllowed" />
|
||||
|
||||
<!-- Filenames MUST be lowercase. -->
|
||||
<rule ref="Generic.Files.LowercasedFilename" />
|
||||
|
||||
<!-- The function brace MUST be on the line following the function declaration
|
||||
and MUST be indented to the same column as the start of the function declaration. -->
|
||||
<rule ref="Generic.Functions.OpeningFunctionBraceBsdAllman" />
|
||||
|
||||
<!-- There MUST be exactly one space after a cast. -->
|
||||
<rule ref="Generic.Formatting.SpaceAfterCast" />
|
||||
|
||||
|
@ -35,6 +42,20 @@
|
|||
<!-- Each file MUST end with exactly one newline character -->
|
||||
<rule ref="PSR2.Files.EndFileNewline" />
|
||||
|
||||
<!-- When referencing arrays there MUST NOT be any whitespace around the opening bracket
|
||||
or before the closing bracket. -->
|
||||
<rule ref="Squiz.Arrays.ArrayBracketSpacing" />
|
||||
|
||||
<!-- The "else if" statement MUST be written with a space between the words else and if. -->
|
||||
<rule ref="Squiz.ControlStructures.ElseIfDeclaration" />
|
||||
|
||||
<!-- There MUST be a space between each element of a foreach loop. -->
|
||||
<rule ref="Squiz.ControlStructures.ForEachLoopDeclaration" />
|
||||
|
||||
<!-- In a for loop declaration, there MUST be no space inside the brackets
|
||||
and there MUST be 0 spaces before and 1 space after semicolons. -->
|
||||
<rule ref="Squiz.ControlStructures.ForLoopDeclaration" />
|
||||
|
||||
<!-- In the argument list, there MUST NOT be a space before each comma,
|
||||
and there MUST be one space after each comma. -->
|
||||
<rule ref="Squiz.Functions.FunctionDeclarationArgumentSpacing">
|
||||
|
@ -44,6 +65,9 @@
|
|||
</rule>
|
||||
<rule ref="Squiz.Functions.FunctionDeclarationArgumentSpacing.SpacingAfterHint" />
|
||||
|
||||
<!-- All built-in PHP functions MUST be called lowercased. -->
|
||||
<rule ref="Squiz.Functions.LowercaseFunctionKeywords" />
|
||||
|
||||
<!-- The eval() function MUST NOT be used. -->
|
||||
<rule ref="Squiz.PHP.Eval" />
|
||||
|
||||
|
|
|
@ -22,6 +22,9 @@
|
|||
<!-- PHP keywords MUST be in lower case. -->
|
||||
<rule ref="Generic.PHP.LowerCaseKeyword" />
|
||||
|
||||
<!-- Constructors MUST be called __construct() instead of after the class. -->
|
||||
<rule ref="Generic.NamingConventions.ConstructorName" />
|
||||
|
||||
<!-- Classes etc. MUST be namespaced -->
|
||||
<rule ref="PSR1.Classes.ClassDeclaration.MissingNamespace" />
|
||||
|
||||
|
|
|
@ -39,7 +39,8 @@ class recursive_event_filter_iterator extends \RecursiveFilterIterator
|
|||
*
|
||||
* @return recursive_event_filter_iterator
|
||||
*/
|
||||
public function getChildren() {
|
||||
public function getChildren()
|
||||
{
|
||||
return new self($this->getInnerIterator()->getChildren(), $this->root_path);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue