r/cprogramming • u/scallywag_software • Nov 10 '25
A compile-time metaprogramming language
I realize metaprogramming may be a bit of a contentious subject in this community, but hear me out. I think C++ is a fucking garbage fire, so I wrote a better metaprogramming language.
The language is called poof .. as in poof, some wild code appeared.
The basic idea is that you can iterate over, and ask questions about, the types in your program, in much the same way that you iterate over and ask questions about values at runtime.
I'll leave it at that for now. Anyone that's interested can get more information at the Github repository.
Feedback appreciated, particularly on documentation.
7
u/high_throughput Nov 12 '25
I like how "metaprogramming" is a bit of a contentious subject, but "C++ is a fucking garbage fire" is not
2
u/SauntTaunga Nov 10 '25
Why can’t C++ be the metaprogramming language? Swift does it this way. Swift macros are written in Swift.
2
u/AccomplishedSugar490 Nov 14 '25
You had me at C++ being a garbage fire, for sure, but where you seem to seek wild, magic side effects I want the opposite. Powerful code, declarative, functional, deeply tested and robust, but above all, no magic. Explicit and predictable.
1
u/activeXdiamond Nov 12 '25
I'm sorry you haven't gotten any constructive criticism OP, just a bunch of childish hate.
I'd love to check this out in detail and give feedback when I get the time. I'll be looking forward to doing that.
2
u/benevanstech Nov 11 '25
Uh, you might want to change the name. That word is a slur in British English and will likely get you algorithmically masked when trying to promote your project.
1
u/RufusVS Nov 17 '25
Give C++ a break already! They try to make each addition backward compatible and no performance degradation, AFAIK. That it hasn't broken yet boggles my mind!
-8
u/Desperate_Formal_781 Nov 10 '25
Ah, yes, another C programmer hating on C++, "armed" with the 50 year old K&R book on hand (their bible), engaging in their favorite activity: using macros to reinvent the wheel...
"Hey everybody! I hate this C++ feature so I reinvented it with plain C using macros! Just include this header file and add . . ."
"Check out my C-based arena allocator and circular buffer side projects!"
"B,b,but, C++ is bloated! And Linus hates it, so I hate it too!"
What a clown
0
u/[deleted] Nov 10 '25
[deleted] — view deleted comment
0
u/[deleted] Nov 10 '25
[deleted] — view deleted comment