| 
        php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
  [2013-07-26 14:12 UTC] marshall dot sorenson at gmail dot com
 Description: ------------ It would be AMAZING if there was an additional extended comment syntax which allowed nesting and overrode C-style comments. The idea would be to only match the last comment closure per file to allow commenting out large blocks of functions which are PHPdoc'd or where a developer used C-style comments for multi-line comments. This would only be useful during development since scripts would have to be backwards compatible with older PHP versions. I have been a PHP developer for 12 years and this would help immensely when debugging code "inherited" from another developer! Even if it could only be enabled with a run time INI setting, that would be fantastic just to have it available. Perhaps even the tokens could be customized via INI setting. I am imagining something like this... /*=== foo // bar # baz /* fu */ ===*/ man /* chu */ ===*/ If there is any interest in this I would be willing to work on the patch but would need some mentoring. PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits             
             | 
    |||||||||||||||||||||||||||
            
                 
                Copyright © 2001-2025 The PHP GroupAll rights reserved.  | 
        Last updated: Tue Nov 04 14:00:01 2025 UTC | 
The functionality you're looking for is already there, if ($cond1) { function hello() { /* version 1 */ } } else if ($cond2) { function hello() { /* version 2 */ } } else ....