papers
carbon-lang
| papers | carbon-lang | |
|---|---|---|
| 89 | 197 | |
| 41 | 33,550 | |
| - | 0.4% | |
| 4.0 | 9.9 | |
| 3 months ago | 5 days ago | |
| Perl | C++ | |
| - | GNU General Public License v3.0 or later |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
papers
- C++26: Erroneous Behaviour
The interpretation is probably up for some debate especially since meeting details are not public, but some relevant links are:
- The P3390R0 Safe C++ proposal and the related vote in the 2024-11 Wrocław meeting: https://github.com/cplusplus/papers/issues/2045
- The adoption of the paper P3466 R1 (Re)affirm design principles for future C++ evolution at the same meeting, which contains language which can be interpreted as preemptively foreclosing a Safe C++-style approach: https://github.com/cplusplus/papers/issues/2121
- A 20 year old bug in GTA San Andreas surfaced in Windows 11 24H2
And yet, there is a good chance that C++ will start doing exactly this [1]. Because [2]:
> The performance impact is negligible (less that 0.5% regression) to slightly positive (that is, some code gets faster by up to 1%). The code size impact is negligible (smaller than 0.5%). Compile-time regressions are negligible. Were overheads to matter for particular coding patterns, compilers would be able to obviate most of them.
> The only significant performance/code regressions are when code has very large automatic storage duration objects. We provide an attribute to opt-out of zero-initialization of objects of automatic storage duration. We then expect that programmer can audit their code for this attribute, and ensure that the unsafe subset of C++ is used in a safe manner.
> This change was not possible 30 years ago because optimizations simply were not as good as they are today, and the costs were too high. The costs are now negligible.
[1] https://github.com/cplusplus/papers/issues/1401
[2] https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2023/p27...
- Malloc broke Serenity's JPGLoader, or: how to win the lottery
For whatever its worth, if we wait long enough C++ will include the equivalent of `malloc_good_size`. https://github.com/cplusplus/papers/issues/18
- Reflection for C++26
https://github.com/cplusplus/papers/issues/1668#issuecomment...
Looks like it did very well in St. Louis!
- Qt and C++ Trivial Relocation (Part 1)
It is slowly making its way through the standards committee. https://github.com/cplusplus/papers/issues/43
The author has a fork of clang and gcc with some pretty impressive speedups, so I’m hopeful! https://lists.isocpp.org/sg14/2024/04/1127.php
- Learn Modern C++
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
- The insanity of compile time programming
- P1673 A free function linear algebra interface based on the BLAS
- When will std::linalg make it into a new C++ release?
See https://github.com/cplusplus/papers/issues/557
- C++ Papercuts
Bringing editions to C++ failed, and I am not aware of anyone trying to tackle the issues https://github.com/cplusplus/papers/issues/631
(I could be wrong though! I follow the committee more than you may guess, but not as much as to think I know everything about what's going on.)
carbon-lang
- Fast, Memory-Efficient Hash Table in Java: Borrowing the Best Ideas
FYI, we ended up implementing a _really_ nice SWAR version in the Carbon derivative of SwissTable that might be worth looking at for inspiration: https://github.com/carbon-language/carbon-lang/blob/trunk/co...
Can see the rest of that file and the adjacent `raw_hashtable.h` for the rest of the SwissTable-like implementation and `hashing.h` for the hash function.
FWIW, it consistently out-performs SwissTable in some respects, but uses a weaker but faster hash function that is good enough for the hash table, but not good for other use cases.
- Carbon Values, Variables, and Pointers
- Is Zig's New Writer Unsafe?
Check out Carbon, its the Kotlin of C++ ;)
I am not a C++ guy, but when Carbon is finally stable and hits the mainstream, I will definitely start trying out Carbon.
https://github.com/carbon-language/carbon-lang
- Carbon Copy No.8: Classes Part II
- Carbon Language: An experimental successor to C++
- The Carbon Language Project has published the first update on Memory Safety
- Initialization in C++ is bonkers (2017)
The latest Carbon newsletter is here, from March: https://github.com/carbon-language/carbon-lang/discussions/5...
- Matt Godbolt sold me on Rust (by showing me C++)
There has been talk of new language frontends for C++:
Cpp2 (Herb Sutter's brainchild): https://hsutter.github.io/cppfront/
Carbon (from Google): https://github.com/carbon-language/carbon-lang
In principle those could enable a safe subset by default, which would (except when explicitly opted-out) provide similar safety guarantees to Rust, at least at the language level. It's still up to the community to design safe APIs around those features, even if the languages exist. Rust has a massive advantage here that the community built the ecosystem with safety in mind from day 1, so it's not just the language that's safe, but the APIs of various libraries are often designed in an abuse-resistant way. C++ is too much of a zoo to ever do that in a coherent way. And even if you wanted to, the "safe" variants are still in their infancy, so the foundations aren't there yet to build upon.
I don't know what chance Cpp2 or Carbon have, but I think you need something as radical as one of these options to ever stand a chance of meaningfully making C++ safer. Whether they'll take off (and before Rust eats the world) is anyone's guess.
- Kickstart insight needed: A new retrofitted C dialect?
Kind of along these lines but for C++: https://docs.carbon-lang.dev/
What are some alternatives?
LEWG - Project planning for the C++ Library Evolution Working Group
rust - Empowering everyone to build reliable and efficient software.
circle - The compiler is available for download. Get it!
Odin - Odin Programming Language
{fmt} - A modern formatting library
cppfront - A personal experimental C++ Syntax 2 -> Syntax 1 compiler