A handwritten recursive-descent parser for PHP written in Rust, for fun.
```rust use phpparserrs::*;
let mut lexer = Lexer::new(None); let tokens = lexer.tokenize(&source_code[..]).unwrap();
let mut parser = Parser::new(None); let ast = parser.parse(tokens).unwrap(); ```
Warning: This crate is not ready for any form of production use yet. There are still a lot of things missing from the parser, so please use at your own risk.
All contributions to this repository are welcome. It's the perfect project for Rust beginners since we don't use many of Rust's complex features and the core concepts in the parser are purposely simple.
If you do wish to contribute, we just ask you to follow a few simple rules.