Menu

#24 PHP 5 Parser

open
None
5
2007-06-02
2004-05-26
No

The parser for PHP files doesn't work well on PHP 5. The
new construct for access (private, public, protected,
etc.) break the app.
So, I created my own version of php.c.
Take a look, please.

Discussion

  • Claudio Bustos

    Claudio Bustos - 2004-05-26

    PHP 5 Parser

     
  • Roel Vanhout (RIKS bv)

    Logged In: YES
    user_id=1430288

    I have tested this parser and as far as I can tell, it works
    great. I did have to move one declaration of a variable to
    the beginning of the function to make it compile under
    Visual Studio .Net 2003 (standard C only allows declarations
    at the beginning of a function, but gcc allows it in its
    default configuration last time I checked).

     
  • Jean-Baptiste Rouquier

    Logged In: YES
    user_id=883682
    Originator: NO

    quick workaround if one doesn't want to recompile: add the option
    --regex-php="/(protected|private|static|abstract|public|[ \t])*function[ \t]*([_a-zA-Z0-9]+)[ \t]*\(/\2/"

     
  • Elliott Hughes

    Elliott Hughes - 2007-06-02
    • assigned_to: nobody --> jafl
     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.