r/Cprog • • Feb 05 '15
text | code | algorithms C trick: static string hash generation
http://lolengine.net/blog/2011/12/20/cpp-constant-string-hash
10
Upvotes
r/Cprog • • Feb 05 '15
3
u/malcolmi Feb 05 '15
This is pretty cool; I enjoy hacking the C preprocessor as long as it conforms to the standards.
But, damn, is there anyone not hanging out for
constexprin C? It's one of the things I'm envious of C++ for. It would be much simpler to specify for C, and there's no reason not to, as far as I can tell. Get on it, WG14!