Re:A nice, little known C feature: Static array indices in p...
by shurcooL on Monday February 18, 2013 @02:59PM
(#5240261)
It's possible to write tools that generate code instead of building it into the language too. I wonder if it can be done better than building it into the language.
[ Parent
| on HN ]
Re:A nice, little known C feature: Static array indices in p...
by dchest on Monday February 18, 2013 @03:06PM
(#5240305)
Here's one https://github.com/droundy/gotgo
Re:A nice, little known C feature: Static array indices in p...
by frou_dh on Monday February 18, 2013 @03:28PM
(#5240421)
You could contrast achieving generics using C preprocessor gymnastics versus C++ templates.
Re:A nice, little known C feature: Static array indices in p...
by shurcooL on Monday February 18, 2013 @04:46PM
(#5240937)
C preprocessor stuff works with text and text only. That's why it's quite hard to make things elegant. Tools can work with text and anything else you can think of. So they can potentially be better. But I don't know what could be done at this point (in fact, this might be a good problem to be analyzed from a theoretical side).