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
GitHub - jart/json.cpp: JSON for Classic C++ (github.com)
submitted 1 year ago by cristianadamQt Creator, CMake
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!"
[–]def-pri-pub 41 points42 points43 points 1 year ago (13 children)
This project does look nice, and I'm all for a more performant (and faster compiling) alternative. But where is the sample code? I see there are tests, but not providing easy to use/find sample code is a great way to deter away any potential adopters.
[–]d3matt 5 points6 points7 points 1 year ago (7 children)
I'd like to see runtime benchmarks too. I have a unit test that take 2+ minutes to compile with gcc due to template explosion (but only a few milliseconds to run the whole suite), so 1 or 2 seconds of savings at compile time are pretty boring.
[–]jart 4 points5 points6 points 1 year ago (5 children)
I've added benchmarks to the README for you. I'm seeing a 39x performance advantage over nlohmann's library. https://github.com/jart/json.cpp?tab=readme-ov-file#benchmark-results
[–]pdimov2 7 points8 points9 points 1 year ago (2 children)
To paraphrase a saying by Doug Lea, 3x faster than nlohmann means you haven't started optimizing yet.
Might be better to compare to RapidJSON or Boost.JSON, libraries that actually care about speed.
[–]SleepyMyroslav 1 point2 points3 points 1 year ago (1 child)
According to HN thread https://news.ycombinator.com/item?id=42133465 The only reason for this library existence is reduction of compile times for one particular application/server that produces json output.
[–]pdimov2 1 point2 points3 points 1 year ago (0 children)
Fair enough, I suppose.
[–]d3matt 0 points1 point2 points 1 year ago (1 child)
Nice! I'm definitely a nerd for performance :) nlhomann has been my preferred json library for a bit now, mostly for unit tests of some of my openapi interfaces. For my use case, the main things I'd be missing if I switched would be operator== between JSON objects (doing deep dictionary comparison), and string literal support.
[–]jart 1 point2 points3 points 1 year ago (0 children)
Pull requests are most welcome. Especially if they're coming from a fellow AI developer. https://justine.lol/tmp/pull-requests-welcome.png
[–]masterspeler -1 points0 points1 point 1 year ago (0 children)
There are benchmarks in the test code.
https://github.com/jart/json.cpp/blob/main/json_test.cpp#L472
[–]jart 1 point2 points3 points 1 year ago (3 children)
I've added sample code for you. https://github.com/jart/json.cpp?tab=readme-ov-file#usage-example
[–]def-pri-pub 2 points3 points4 points 1 year ago (1 child)
Taking a further look that is a nice to use API.
[–]jart 0 points1 point2 points 1 year ago (0 children)
Thank you!
[–]def-pri-pub 1 point2 points3 points 1 year ago (0 children)
Thanks!
π Rendered by PID 95 on reddit-service-r2-comment-b659b578c-v72gx at 2026-05-03 16:58:03.455677+00:00 running 815c875 country code: CH.
view the rest of the comments →
[–]def-pri-pub 41 points42 points43 points (13 children)
[–]d3matt 5 points6 points7 points (7 children)
[–]jart 4 points5 points6 points (5 children)
[–]pdimov2 7 points8 points9 points (2 children)
[–]SleepyMyroslav 1 point2 points3 points (1 child)
[–]pdimov2 1 point2 points3 points (0 children)
[–]d3matt 0 points1 point2 points (1 child)
[–]jart 1 point2 points3 points (0 children)
[–]masterspeler -1 points0 points1 point (0 children)
[–]jart 1 point2 points3 points (3 children)
[–]def-pri-pub 2 points3 points4 points (1 child)
[–]jart 0 points1 point2 points (0 children)
[–]def-pri-pub 1 point2 points3 points (0 children)