First contact with open .NET

Completed on 13-Feb-2016 (47 days) -- Updated on 19-Nov-2016

Project 7 in full-screenProject 7 in PDF
Introduction >
Open .NET overview

Microsoft has decided to make the whole .NET Framework open source. It is a huge step in the right direction with lots of implications, although all this is outside the scope of the current project. Only the following code repositories are relevant here:
  • CoreCLR. It contains the most basic parts. The majority of the code is written in (mostly unmanaged/unsafe) C# and C++.
  • CoreFX. It contains the remaining parts of the .NET Framework. Most of the code is written in (mainly managed) C#, but also in C++ & VB.NET.
  • Roslyn. It contains the last versions of the C#/VB.NET compilers (and all what is related to compilation/Visual Studio, including a new subsystem delivering relevant insights about the whole process). Most of the code is written in (mainly managed) C# & VB.NET.
As shown in the corresponding page, I am mostly experienced in (managed) C# and VB.NET, also in algorithm-building/efficiency-improvement. From the point of view of the programming language, Roslyn (or even CoreFX) seems more appealing to me; on the other hand, the exact programming language is not a big problem, mainly when dealing with properly-working existing codes and by bearing in mind my relevant expertise in different environments.

This first open .NET project deals with CoreCLR because of providing the kind of access to basic parts which is more appealing to a code-improver like me (at least for open-source contributions, this is my favourite role). More specifically, this project is mostly focused on ParseNumber (and on all the code related to it), which takes care of the string-analysis actions needed by the parsing methods of all the .NET numeric types (although this project is mostly focused on decimal.Parse and decimal.TryParse). It is contained in the file Number.cs, which is part of mscorlib.dll where the most essential .NET functionalities are defined.


The PR associated with this project was accepted by the .NET team and merged into the CoreCLR code; the proposed modifications were even extended to other repositories (i.e., CoreRT and CoreFX).

Most of the contents of the current project are still valid, although the following issues have to be taken into account:
  • I preferred to not remove certain parts which, despite being somehow obsolete, contain valuable ideas.
    For example, all the contents related to CoreRun.exe belong to this category. Note that, when this project was written, the user had to rely on this program directly via command prompt (not the case with the current Core-based approach). To know more about this specific issue, take a look at the also-updated Project 8.
  • Additionally to comments on these lines at the bottom of various sections, I added the new Tests > Additional tests.