News for hackers. Stuff that matters.
Re:Is the C++ preprocessor still needed? by kevin_thibedeau on Tuesday May 09, 2017 @08:16PM (#14304964)
You would be better served with m4.
Re:Is the C++ preprocessor still needed? by flukus on Wednesday May 10, 2017 @03:43AM (#14306530)
I looked into m4 recently but it seems to be about the worst template engine imaginable. I'd take the c pre-processor over that any day.

In the end I opted for a sed/awk/cat combo instead.

Re:Is the C++ preprocessor still needed? by daxelrod on Wednesday May 10, 2017 @08:09AM (#14307540)
Could you please point to some good m4 learning and reference resources?

The only time I had to write m4 was admittedly in the context of autotools, but I found it really difficult to get answers to my questions about how everything worked.

Re:Is the C++ preprocessor still needed? by s_kilk on Wednesday May 10, 2017 @09:05AM (#14307821)
I wrote up a little tutorial on using m4 as a CSS pre-processor:

http://blog.00null.net/post/144763147991/use-the-unix-m4-as-...

Re:Is the C++ preprocessor still needed? by flukus on Wednesday May 10, 2017 @11:04PM (#14313572)
Wow thanks, that's a much better intro to the ones I cam across like this (http://mbreen.com/m4.html). I may have to reevaluate it.