Doc #72415 [Opn->Nab]: PSR2 VS PHP.net
| From: | requinix@php.net | Date: | Wed, 15 Jun 2016 15:22:18 +0000 |
| Subject: | Doc #72415 [Opn->Nab]: PSR2 VS PHP.net | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-13532@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=72415&edit=1
ID: 72415
Updated by: requinix@php.net
Reported by: nicolas dot charvet at imie dot fr
Summary: PSR2 VS PHP.net
-Status: Open
+Status: Not a bug
Type: Documentation Problem
Package: Documentation problem
PHP Version: 5.6.22
Block user comment: N
Private report: N
New Comment:
The documentation on php.net is official and gives information about what is and is not permitted by
the PHP language. Leading underscores are permitted.
The PSRs are "best practice" coding style guides that are developed by the community.
PSR-2 discourages the use of leading underscores for class properties.
Previous Comments:
------------------------------------------------------------------------
[2016-06-15 14:57:05] nicolas dot charvet at imie dot fr
Description:
------------
---
From manual page: http://www.php.net/language.variables.basics
---
Hello,
the PSR2 seems asking to stop using the underscore in php variable declaration.
http://www.php-fig.org/psr/psr-2/#4-2-properties
But documentation php are always references .
http://php.net/manual/fr/language.variables.basics.php
What is the proper documentation ?
Thank you.
Nicolas.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=72415&edit=1