4 ms·
The internal source code of PHP was often a mess of macros everywhere My understanding, from people here that seemed to know what they are talking about, is th
by kbenson 13y ago
The internal source code of PHP was often a mess of macros everywhere
My understanding, from people here that seemed to know what they are talking about, is that generally macros are how these languages are implemented when done in C, for various reasons. So much so in fact, that you are really writing a DSL layered over C. I doubt Python, Ruby or Perl are any different (actually I know Perl relies heavily on macros in the source for its interpreter).
Edit: s/Rudy/Ruby/. duh.
- iagooar 13y agoThe Ruby source code is also a DSL build on top of a bunch of macros.
- justincormack 13y agoLua is proper C code, and readable too. Macros are not necessary.
- seabee 13y agoLua has a much smaller codebase and is simpler than PHP, so I'm not sure the comparison is apt.