Skip to content

Commit 6c129c9

Browse files
committed
Merge pull request joomla#38 from betweenbrain/php-keywords
Adds General section with notation of PSR-2 usage on Keywords and True/F...
2 parents 76e09a9 + a0b8642 commit 6c129c9

File tree

1 file changed

+10
-0
lines changed
  • manual/en-US/coding-standards/chapters

1 file changed

+10
-0
lines changed

manual/en-US/coding-standards/chapters/php.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@ For files that contain only PHP code, the closing tag (`?>`) should not be inclu
88

99
Files should always end with a blank new line.
1010

11+
### General
12+
13+
Pursuant to PSR-2 [Keywords and True/False/Null][]
14+
15+
> PHP [keywords][] MUST be in lower case.
16+
> The PHP constants `true`, `false`, and `null` MUST be in lower case.
17+
18+
[Keywords and True/False/Null]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md#25-keywords-and-truefalsenull
19+
[keywords]: http://php.net/manual/en/reserved.keywords.php
20+
1121
### Including Code
1222

1323
Anywhere you are unconditionally including a file, use `require_once`. Anywhere you are conditionally including a file (for example, factory methods), use `include_once`. Either of these will ensure that files are included only once. They share the same file list, so you don't need to worry about mixing them. A file included with `require_once` will not be included again by `include_once`.

0 commit comments

Comments
 (0)