Php-parser written in golang v0.3 is released
1–10 of 28 posts
Re: Php-parser written in golang v0.3 is released
#2Re: Php-parser written in golang v0.3 is released
#3Obviously not every project needs a "why?", and this is a technically cool endeavour that stands on its own..
A few ideas I can think of for "Why?":
* Static analysis of a codebase looking for bad practices or errors
* Feeding the structured output into code-gen for another language, to start a porting project
* //STEP MISSING//, Profit?
Anything else?Re: Php-parser written in golang v0.3 is released
#4There's a [dead] comment that asks "Why?"... Obviously not every project needs a "why?", and this is a technically cool endeavour that stands on its own.. A few ideas I can think of for "Why?": * Static analysis of a codebase looking for bad practices or errors * Feeding the structured output into code-gen for another language, to start a porting project * //STEP MISSING//, Profit? Anything else?
Re: Php-parser written in golang v0.3 is released
#5If that is it, you'd probably be better off just using the PHP parser (https://github.com/nikic/PHP-Parser).
If you are writing analyzers for PHP, you must know it enough to right an analyzer in actual PHP. Why Go?
I can't see a lot of people using this.
Re: Php-parser written in golang v0.3 is released
#6There's a [dead] comment that asks "Why?"... Obviously not every project needs a "why?", and this is a technically cool endeavour that stands on its own.. A few ideas I can think of for "Why?": * Static analysis of a codebase looking for bad practices or errors * Feeding the structured output into code-gen for another language, to start a porting project * //STEP MISSING//, Profit? Anything else?
So the answer might just be "because I can and I want to".
This is the talk, IIRC: "Yak shaving is best shaving" https://www.youtube.com/watch?v=nY_Pl2x7Fgs
Re: Php-parser written in golang v0.3 is released
#7What is the purpose of this? Just static analysis? If that is it, you'd probably be better off just using the PHP parser ( https://github.com/nikic/PHP-Parser ). If you are writing analyzers for PHP, you must know it enough to right an analyzer in actual PHP. Why Go? I can't see a lot of people using this.
nikic/PHP-Parser is feature-complete/mature/stable and developed by one of the most knowledgeable members of the PHP internals core development team. It is the library powering many PHP dev tools; static analysis included.
I can see that creating a tool like this is an excellent learning experience, but I don't see why anyone else should care.
Re: Php-parser written in golang v0.3 is released
#8Re: Php-parser written in golang v0.3 is released
#9There's a [dead] comment that asks "Why?"... Obviously not every project needs a "why?", and this is a technically cool endeavour that stands on its own.. A few ideas I can think of for "Why?": * Static analysis of a codebase looking for bad practices or errors * Feeding the structured output into code-gen for another language, to start a porting project * //STEP MISSING//, Profit? Anything else?
Aaron Patterson, the author of phuby ( https://github.com/tenderlove/phuby ) once explained in a talk what's good about embedding a php interpreter in ruby. The gist, as I remember was: Technically speaking, it makes no sense. It will never become anything useful. But you can make it work, and you might learn something useful along the way. IIRC, he found a couple of very interesting (and useful) issues along the way…
Re: Php-parser written in golang v0.3 is released
#10Earlier quoted context omitted.
Aaron Patterson, the author of phuby ( https://github.com/tenderlove/phuby ) once explained in a talk what's good about embedding a php interpreter in ruby. The gist, as I remember was: Technically speaking, it makes no sense. It will never become anything useful. But you can make it work, and you might learn something useful along the way. IIRC, he found a couple of very interesting (and useful) issues along the way…
Embedding an interpreter in another language can certainly be useful, but this is just a parser.