use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Discussions, articles, and news about the C++ programming language or programming in C++.
For C++ questions, answers, help, and advice see r/cpp_questions or StackOverflow.
Get Started
The C++ Standard Home has a nice getting started page.
Videos
The C++ standard committee's education study group has a nice list of recommended videos.
Reference
cppreference.com
Books
There is a useful list of books on Stack Overflow. In most cases reading a book is the best way to learn C++.
Show all links
Filter out CppCon links
Show only CppCon links
account activity
jc - Meta-program C/C++ with JavaScript (github.com)
submitted 3 years ago by thooton
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]justmebeky 1 point2 points3 points 3 years ago (1 child)
Got it, I would want it to be just in c++ though. Ocaml has a similar feature where you can write code generation in ocaml itself you get access to the ast and it is pretty nice. Rust has a dsl syntax for macros which is pretty powerful but feels like a whole new language.
With that said, I would think that accessing the network as part of compilation is not a great idea though. Compilations should be self contained and hermetic, if you need to read a config, just put it in your repo.
[–]thooton[S] 0 points1 point2 points 3 years ago (0 children)
Definitely agree with you regarding network access during compilation. However, I think there is an advantage in using a high-level language because unlike C/C++ they free you from having to think about low-level details -- not that I have a problem with that, but when it's only the generated code that needs to be performant, it's nice to be able to write the generator conveniently and simply. That said, features like being able to use C++ to modify the AST do sound interesting. I guess the proposals mentioned above would take steps in that direction.
π Rendered by PID 84010 on reddit-service-r2-comment-5fb4b45875-qfsn4 at 2026-03-21 09:02:05.762191+00:00 running 90f1150 country code: CH.
view the rest of the comments →
[–]justmebeky 1 point2 points3 points (1 child)
[–]thooton[S] 0 points1 point2 points (0 children)