What's not mentioned in the announcement (at least based on a quick skim) is that EDG the company is winding down, which is likely the reason why they're open sourcing the front end.
Sad. Those folks are some brilliant computer scientists.
splicebot 37 minutes ago [-]
Not really sad. They are getting older, worked for themselves doing presumably what they wanted their entire career, now they are done. They could have built the company up, instead it has been common knowledge for close to 10 years they were going to retire 'any day now.'
vintagedave 3 hours ago [-]
Wow. This is big news for C++.
For background -- and I am not an expert here -- their C++ frontend is widely known. I first heard of it because Visual C++'s Intellisense uses it, which was notable because VC does not use the msvc frontend for its own completion. I understand it's been either used or evaluated for other frontends in the past too. I worked as PM for one C++ product, and was fortunate to be able to learn a lot from our engineers; we didn't use it, but they thought highly of EDG.
It has a very strong reputation for being correct. And as such, I think open sourcing it will be a very beneficial thing for the C++ community.
jcranmer 2 hours ago [-]
There are essentially four C++ frontends: gcc, clang, MSVC, and EDG. Pretty much every C++ compiler is a reskinned version of one of those compilers. Most of the proprietary compilers have been slinking away from using EDG to using clang (e.g., Intel did this transition a few years ago).
The reason why the EDG frontend is being open-sourced is because EDG itself is closing up shop, and the open sourcing is an interim solution as EDG's customers work on migrating to using Clang instead. So... it's really not good news, because it means that one of the frontends is basically reaching end-of-life.
vintagedave 1 hours ago [-]
I’m hopeful open sourcing means a new life for EDG.
tialaramex 13 minutes ago [-]
C++ is a sprawling language which will consume any available amount of effort or goodwill. So I don't expect you will see a "new life" for this codebase while continued effort on the "big three" compilers happens.
whobre 1 hours ago [-]
I wouldn’t hold my breath, but I hope I am wrong
lelanthran 2 hours ago [-]
> Wow. This is big news for C++.
But also quite sad. They've announced that they are closing down.
genxy 5 minutes ago [-]
It is great news, it means that C++ can slowly wither as other organisms occupy the same niche.
carterschonwald 3 hours ago [-]
i dont even use cpp and my immediate response was oh shit this is a big deal
> LLVM Exceptions to the Apache 2.0 License
> As an exception, if, as a result of your compiling your source code, portions of this Software are embedded into an Object form of such source code, you may redistribute such embedded portions in such Object form without complying with the conditions of Sections 4(a), 4(b) and 4(d) of the License.
> In addition, if you combine or link compiled forms of this Software with software that is licensed under the GPLv2 ("Combined Software") and if a court of competent jurisdiction determines that the patent provision (Section 3), the indemnity provision (Section 9) or other Section of the License conflicts with the conditions of the GPLv2, you may retroactively and prospectively choose to deem waived or otherwise exclude such Section(s) of the License, but only in their entirety and only with respect to the Combined Software.
I don't understand the second part. Can someone explain it to me?
jcranmer 2 hours ago [-]
The Apache's patent clauses conflict with the requirements of the GPL license. GPLv3 contains explicit wording to handle this conflict; GPLv2 does not. The exception here is adding wording to let this Apache-licensed code be used with GPLv2 code in the same way that it would normally be usable with GPLv3.
trebligdivad 3 hours ago [-]
It's got history! That's really unusual for moves to open-source; the dates on the earliest commits are in 1990 and they do go forward in time so that's really unusual to have that much history. I bet there's some fun stuff in there.
kccqzy 3 hours ago [-]
If I remember correctly, EDG was the only C++ implementation that actually attempted to implement the export keyword for templates in old C++. It was this implementation experience that informed the deprecation of export. EDG is a major influence in the development of C++.
bluGill 2 hours ago [-]
Slight correction, the other compiler/front end writers more or less read the white paper and said "that is what we thought it would be like and thus why we didn't implement it".
Imagine telling your competitors not to copy some feature you have and them listening!
pjmlp 3 hours ago [-]
Yes, it was also where C++26 static reflection was prototyped, as another example of its influence.
One of EDG developers prototyped his idea, and brought it to WG21 when it seemed reflection as originally thought for C++17 was never happening.
andrewaylett 1 hours ago [-]
I have fond memories of working on an embedded systems compiler that used the EDG front-end — that would be almost 20 years ago now.
We certainly held it in high regard. It was rare that a compiler bug was in their code rather than ours :).
etyp 3 hours ago [-]
Ah, I used EDG for static analysis, but joined when we were switching over to using Clang for the frontend. I can't say for sure, but part of it was definitely just to save money using open source. The code that was hacked on top of EDG was also ridiculous, so there was a lot of accumulated tech debt there.
Looking back at that code definitely brings back memories. As a consumer of both frontends, I will say I much preferred working with Clang's. Both needed extra work on top to support everything we needed. Maybe I'm just not as acquainted with C as I would like to be. It's cool to look at this again, though.
compiler-guy 2 hours ago [-]
One interesting thing about the EDG front end is that it can emulate all the others (and in various versions of the others) and what they support, and the errors they might detect.
It isn't perfect, but it is awfully good.
Another interesting thing is that in 1999ish, when SGI open-sourced the Irix compiler (known as sgicc) into open-64, the it used a terribly hacked version of gcc as a front end to generate its internal intermediate representation.
This was because sgicc, even back then, used EDG as a front end, and EDG wasn't open and couldn't be opened up at the time.
The combination worked OK, but was pretty hacky, and I wonder if open64 would have gotten more traction than it did if it had been able to use EDG, or perhaps some other front end actually designed as a front end instead of the hacky thing.
suid 3 hours ago [-]
Ooh, fond (and some not so fond) memories of when Silicon Graphics' (MIPS) C and C++ compilers were based on EDG's frontend, with a custom ucode-generating backend, and integrated into CASEVision. Early 1990s.
EDG was just 3 guys back then.
criemen 3 hours ago [-]
Wikipedia claims they have 6 employees, so they didn't exactly enjoy exponential growth over the years ;)
layer8 2 hours ago [-]
The only implementation to ever support the C++98 “export template” feature, as far as I know. I wonder if that’s still in the open-sourced version.
throwaway2037 2 hours ago [-]
I'll never forget working on a personal C++ project in the very early 2000s. In parallel, I was reading Bjarne Stroustrup's famous C++ bible. He diligently explained how the “export template” feature worked. I tried to use it. I was compiling with GCC on Linux. I spent days trying to understand why it didn't work. Finally, I found a blog post explaining why it was so hard to implement, and no open source C++ compilers supported it. What a disappointment!
stuaxo 3 hours ago [-]
"Three tracks, one codebase" this is such an LLM written sentence.
EDIT: But in this case it seems something significant is being released, it would be better with less writing and more human if possible.
dgrunwald 3 hours ago [-]
Despite using C++ for a few years now, the EDG source code is still mostly C code (and in fact, the C++ code is still using the old .c file names). In particular, there's no usage of the C++ standard library.
Where other languages might use inheritance, EDG still uses the C-style `union { ... } variant;`.
On a related note, compiling EDG is extremely fast: on my machine, the EDG frontend compiles in <10s; whereas clang takes >10min (caution unfair comparison: clang includes much more than just a frontend).
smlacy 3 hours ago [-]
I think this is fairly common practice when writing compilers. You ideally want to be able to bootstrap from other languages, and C is a much simpler starting point.
criemen 27 minutes ago [-]
They also have a distinct style/naming convention, see for example `a_list_entry` as type name.
waynecochran 3 hours ago [-]
Yes, of course. It makes complete sense to have the implementation of a C++ compiler to be written in a highly portable and much simpler language like C.
2 hours ago [-]
my-next-account 4 hours ago [-]
What is this?
dgrunwald 4 hours ago [-]
It's one of the 4 big remaining C++ compiler frontends: gcc, clang, MSVC, EDG.
Most other C++ compilers are based on either EDG or clang. (e.g. the Intel C++ compiler used to be based on the EDG frontend, though modern versions are based on clang instead)
The "frontend" is the part of the compiler that understands the input language: lexer, parser, template instantiation, constexpr evaluation, ...
The EDG frontend produces an intermediate representation (IL) that is then used by the different compiler vendors to generate machine code. Or do code analysis.
EDG can also be used as a C++-to-C compiler.
ur-whale 3 hours ago [-]
> EDG can also be used as a C++-to-C compiler.
Nice to see this still exists!
After all, this is how it all started back in the days of - what was it called again ? - yeah, cfront
TLDR EDG C++ is a compiler frontend developed by EDG since the 80s which has been used under the hood for a whole bunch of commercial C and C++ compilers, static analyzers, linters, and IDE code completion tools.
Odds are if you are familiar with a closed source tool in one of those categories above, there's a decent chance it uses EDG's frontend somewhere in it under the hood.
cyberax 3 hours ago [-]
It has an interesting code style, the comments go _after_ the function definition but before the opening bracket.
It looks weird, but it actually makes sense! The flow is more natural - first the function definition, and then the explanation of what it does. It also avoids repeating the function name.
asveikau 8 minutes ago [-]
I've seen that in other code bases. Can't think of them offhand right now.
compiler-guy 50 minutes ago [-]
Code from that era predates the web, and a lot of open source style guides, and even most open source code itself.
So it came up in an era where folks were inventing their own style and the huge homogenizing influence of the gnu standards (and other open source projects) hadn't taken hold.
I like it. It feels like another language, and has its advantages. I really like to know of alternate ways of doing things, even if I don't adopt them myself.
spatulon 2 hours ago [-]
One of the more unusual aspects is the naming convention for types. Most type names use the a_ prefix (e.g. a_statement_ptr), but names beginning with a vowel start with an_ instead (e.g. an_object_lifetime_ptr).
1718627440 3 hours ago [-]
I write comments about what a function does and it's interface before, but comments about the implementation after. Also my pre- and post-conditions go there of course. (I'm mostly writing in C.)
mhh__ 3 hours ago [-]
This is also where conditions go in languages with contracts, I like it
zerr 3 hours ago [-]
This is common in Lisps.
bobmarleybiceps 3 hours ago [-]
never occurred to me to write a comment there, but it actually looks kind of clean imho. Really old C code looked like
void func(var1, var2)
int var1,
char* var2.
{ ... }
perhaps some legacy from that? Probably not, but just first thing that popped into my head since it feels similar :shrug:
ritualdevin 1 hours ago [-]
[dead]
Rendered at 23:18:46 GMT+0000 (UTC) with Wasmer Edge.
https://en.wikipedia.org/wiki/Edison_Design_Group ref 9: https://herbsutter.com/2025/11/10/trip-report-november-2025-...
For background -- and I am not an expert here -- their C++ frontend is widely known. I first heard of it because Visual C++'s Intellisense uses it, which was notable because VC does not use the msvc frontend for its own completion. I understand it's been either used or evaluated for other frontends in the past too. I worked as PM for one C++ product, and was fortunate to be able to learn a lot from our engineers; we didn't use it, but they thought highly of EDG.
It has a very strong reputation for being correct. And as such, I think open sourcing it will be a very beneficial thing for the C++ community.
The reason why the EDG frontend is being open-sourced is because EDG itself is closing up shop, and the open sourcing is an interim solution as EDG's customers work on migrating to using Clang instead. So... it's really not good news, because it means that one of the frontends is basically reaching end-of-life.
But also quite sad. They've announced that they are closing down.
The source code itself: https://github.com/edgcpp/compiler
Documentation: https://edgcpp.org/doc/
And for those curious the license SPDX is: Apache-2.0 WITH LLVM-exception
i.e.
- https://spdx.org/licenses/Apache-2.0.html
- https://spdx.org/licenses/LLVM-exception.html
Imagine telling your competitors not to copy some feature you have and them listening!
One of EDG developers prototyped his idea, and brought it to WG21 when it seemed reflection as originally thought for C++17 was never happening.
We certainly held it in high regard. It was rare that a compiler bug was in their code rather than ours :).
Looking back at that code definitely brings back memories. As a consumer of both frontends, I will say I much preferred working with Clang's. Both needed extra work on top to support everything we needed. Maybe I'm just not as acquainted with C as I would like to be. It's cool to look at this again, though.
It isn't perfect, but it is awfully good.
Another interesting thing is that in 1999ish, when SGI open-sourced the Irix compiler (known as sgicc) into open-64, the it used a terribly hacked version of gcc as a front end to generate its internal intermediate representation.
This was because sgicc, even back then, used EDG as a front end, and EDG wasn't open and couldn't be opened up at the time.
The combination worked OK, but was pretty hacky, and I wonder if open64 would have gotten more traction than it did if it had been able to use EDG, or perhaps some other front end actually designed as a front end instead of the hacky thing.
EDG was just 3 guys back then.
EDIT: But in this case it seems something significant is being released, it would be better with less writing and more human if possible.
Where other languages might use inheritance, EDG still uses the C-style `union { ... } variant;`.
On a related note, compiling EDG is extremely fast: on my machine, the EDG frontend compiles in <10s; whereas clang takes >10min (caution unfair comparison: clang includes much more than just a frontend).
The "frontend" is the part of the compiler that understands the input language: lexer, parser, template instantiation, constexpr evaluation, ... The EDG frontend produces an intermediate representation (IL) that is then used by the different compiler vendors to generate machine code. Or do code analysis.
EDG can also be used as a C++-to-C compiler.
Nice to see this still exists!
After all, this is how it all started back in the days of - what was it called again ? - yeah, cfront
https://en.wikipedia.org/wiki/Cfront
TLDR EDG C++ is a compiler frontend developed by EDG since the 80s which has been used under the hood for a whole bunch of commercial C and C++ compilers, static analyzers, linters, and IDE code completion tools.
Odds are if you are familiar with a closed source tool in one of those categories above, there's a decent chance it uses EDG's frontend somewhere in it under the hood.
It looks weird, but it actually makes sense! The flow is more natural - first the function definition, and then the explanation of what it does. It also avoids repeating the function name.
So it came up in an era where folks were inventing their own style and the huge homogenizing influence of the gnu standards (and other open source projects) hadn't taken hold.
I like it. It feels like another language, and has its advantages. I really like to know of alternate ways of doing things, even if I don't adopt them myself.
void func(var1, var2) int var1, char* var2. { ... }
perhaps some legacy from that? Probably not, but just first thing that popped into my head since it feels similar :shrug: