Learn Modern C++

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • learnmoderncpp-tutorial

    Complete, working programs, plus Markdown sources, from the C++ tutorial hosted at learnmoderncpp.com

  • The introductory tutorial comes with a GitHub repo. Chad move. Makes it easy to put on my e-reader.

    https://github.com/cpp-tutor/learnmoderncpp-tutorial

  • papers

    ISO/IEC JTC1 SC22 WG21 paper scheduling and management (by cplusplus)

  • What's fun is, because everything is decided in papers, we can find out why! https://github.com/cplusplus/papers/issues/884

    Accepted paper here: https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2022/p20...

    > The proposed std::print function improves usability, avoids allocating a temporary std::string object and calling operator<< which performs formatted I/O on text that is already formatted. The number of function calls is reduced to one which, together with std::vformat-like type erasure, results in much smaller binary code (see § 13 Binary code).

    Additionally,

    > Another problem is formatting of Unicode text:

    > std::cout << "Привет, κόσμος!";

    > If the source and execution encoding is UTF-8 this will produce the expected output on most GNU/Linux and macOS systems. Unfortunately on Windows it is almost guaranteed to produce mojibake despite the fact that the system is fully capable of printing Unicode

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • C++ Format

    A modern formatting library

  • > This is from C++23, right?

    std::println is, yes.

    > I wonder how available this is within compilers

    https://en.cppreference.com/w/cpp/compiler_support says clang, gcc, and msvc all support it, though I don't know how recent those versions are off the top of my head.

    In my understanding, with this specific feature, if you want a polyfill for older compilers, or to use some more cutting-edge features that haven't been standardized yet, https://github.com/fmtlib/fmt is available to you.

  • CppCoreGuidelines

    The C++ Core Guidelines are a set of tried-and-true guidelines, rules, and best practices about coding in C++

  • json

    JSON for Modern C++

  • I have not done a "desktop" program in 25+ years and never using C++ (or C), since then I'm mostly a web developer (PHP,Elixir, JS, Kotlin etc).

    I'm currently doing a C++ audio plugin with the Juce framework.

    This website has been a good resource, alongside https://www.learncpp.com

    But I was actually close to give up before using those two things:

    - https://github.com/nlohmann/json : my plugin use a json api backend and the Juce json implementation is atrocious (apparently because of being born in previous c++ version), but this library is GREAT.

    - ChatGPT 4. I'm not sure I would have "succeeded" without it, at least not in a reasonable time frame. ChatGPT 3.5 is slow and does not give good results for my use case but 4 is impressive. And I use in a very dumb way, just posing question in the web UI. I probably could have it directly in MSVC?

    Also I must say, for all its flaws, I have a renewed appreciation for doing UI on the web ;)

  • Monocypher

    An easy to use, easy to deploy crypto library

  • Are you assuming I didn't already do that? For your information I've written an entire cryptographic library in C https://monocypher.org and routinely chose C over C++. My claim that C is broken beyond repair doesn't come from ignorance or hype, it comes from over 15 years of first hand experience.

    And of course, GC and RC aren't fixes, they can't apply in the performance constrained settings C and C++ typically are used for (tiny embedded chips, video games, video encoding…).

    Also there's no way I'll even look at a new language without some form of generics. They're just too damn useful. Sure we could try the Go approach and special case generics for a few core data structures, but I believe a general purpose language needs a way to add custom ones. Heck, even Go fixed its mistakes and added generics after all.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts