1/ It's probably not the first thing you think of, but when we started .NET (COM+) in the late 90s, C# didn't exist yet. We were working on it at the same time as the CLR and the framework. So, you might wonder, what language was being used to generate IL and write the BCL?
2/ The answer is a language that we called SMC that Peter Kukol wrote the compiler for. Peter is a flat out amazing engineer and wrote the core parts of the compiler in just a few days. This unblocked the framework team, allowed vetting the runtime and interpreter, etc.
3/ SMC was a trimmed down C++ variant and the compiler was written in itself (i.e. SMC). It didn't support things like destructors, multiple inheritance, virtual base classes, etc. But, overall it enabled progress that would have otherwise been stalled.
4/ It did introduce a problem for the C# language and compiler team though. Every day more and more code was written in SMC, a language that we did not intend to ship externally. Designing a new language is hard (well, at least, a general purpose one that becomes popular).
5/ So there was a constant balancing act between laying enough of the foundation of the language and the C# compiler to replace SMC and making sure that the design lived up to the goals and ideals the team was striving for. If we waited too long to adopt C#,
6/ there would be too much SMC code written and we might not be able to reasonable port all of it. If we moved too early, the C# language wouldn't have time to bake and we would sacrifice the design aesthetic for expediency.
7/ Folks know how this ends - we eventually felt good enough about the state of the C# language and compiler to begin the migration and ultimately converted the entirety of the framework. The design team was incredibly disciplined and held a hard line
8/ on the design of the language. As far as I can remember there wasn't a single language concession that was made in order to 'rush', despite the pressure. That isn't to say there was no impact though. I'll talk about what it meant for the compiler and IDE in a separate thread,
9/ but there were a small number of features added to unblock the BCL and make migration easier. For example, the __ keywords, like __arglist, __makeref, etc. It also meant that the design team started the practice of meeting 3x a week for multiple hours a day to resolve design
10/ issues. Looking back, it was a heady time, stressful, but exciting.
You can follow @AnsonHorton.
Tip: mention @twtextapp on a Twitter thread with the keyword “unroll” to get a link to it.

Latest Threads Unrolled:

By continuing to use the site, you are consenting to the use of cookies as explained in our Cookie Policy to improve your experience.