A reference compiler and toolchain. #891
LouChiSoft
started this conversation in
Suggestions
Replies: 1 comment
-
Just an FYI: There is a related discussion going on in #915, where my suggestion is |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
First off I realise what I am suggesting is a far far future request that would only happen if the Cppfront experiment is a success. But I think it's worth bearing in mind a feature like this early so that it can be planned for in the event that Cppfront is successful.
One of the things that most of the other C++ successor experiments have in common is that they all have a single toolchain and compiler. I'm not saying that Cpp2 should only have 1 compiler, in fact I think that having multiple compilers and toolchains from different vendors is good because it can encourage innovation to be the best compiler. That being said C++ also has the unfortunate case of new standards that come out not being supported for years after the standard is released.
As an example, take C++ modules. C++ modules were standardised in C++20 and they only really become somewhat usable this year. And even then some of the usable implementations are still listed as an experimental or preview feature, see Microsoft's documentation as an example which lists it as a preview feature.
A reference compiler that supports all the features of a given standard upon release could go a long way to help feature adoption. If more people use a feature from the standard that the reference compiler implements the more likely that compiler developers are going to prioritise that feature in their own compilers. It doesn't even need to be the fastest compiler, both in terms of compile speed and runtime speed. Just fast enough to be usable and in a position where you can say "Hey, a new Cpp2 standard has been released. Try out all the new features now"
If this is out of scope for this repo that's fine, I just think how people build a language is just as important as the language itself. It doesn't matter how amazing your syntax is if building it is the worst experience possible. (Obvously C++ compilation is that bad, but a little hyperbole can't hurt 😂)
Beta Was this translation helpful? Give feedback.
All reactions