> On Jan 8, 2020, at 11:10 AM, Robert Hickman <robehick...@gmail.com> wrote: > > My suggestion was not a preprocessor, but what others have said > already, a 'shim' that goes between the parser/lexer and bytecode > generation which allows user code to inspect and modify the AST. This > idea is not unusual and Python for example can do this. The idea is > the basis of macro systems in Lisps, and Rust has a very nice > implementation of it from what I've seen in passing. The system should > be fully aware of the syntax, scoping, namespaces etc, the lack of > which is the problem with C preprocessor for example. > > With regards to how JAI does this: > > https://www.youtube.com/watch?v=UTqZNujQOlA > https://www.youtube.com/watch?v=59lKAlb6cRg&list=PLmV5I2fxaiCKfxMBrNsU1kgKJXD3PkyxO&index=20&t=0s
Nice! Never heard of JAI but will be checking it out. -Mike -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php