Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How is it that the Mono sources are mostly C#?

Tags:

c#

mono

I just looked at the source of Mono for the first time and I thought I would find a bunch of C or C++ code, instead I found 26,192 .cs files and 7 .cpp files.

I am not totally shocked but it made me think of a quesiton I've always had in the back of my mind:

How does a project end up being written in "itself" like this?

Was an older version of mono more c/c++? Or was there initial effort to create some kind of machine coded compiler...

What's the "trick" here?

like image 732
Aaron Anodide Avatar asked Nov 07 '11 01:11

Aaron Anodide


People also ask

Where can I find mono source code?

Source Code Repository. The Mono source code is hosted on GitHub using the Git source code control system for all of its source code. Although only active contributors get write access to the modules on Git, third party developers can easily fork the code on GitHub or download full copies of the repositories to their own systems.

Where can I find the Mono C compiler?

The Mono C# compiler is part of the `mono’ module in the Mono Git you can get it from our source code server, or you can get nightly download page. You can also browse or download a snapshot of the compiler alone: browse the sources.

What is mono?

Mono is an Open Source free programming language project. It is an implementation of Microsoft’s .NET Framework based on the European association for standardizing information and communication systems ( ECMA) standards for C# language and Common Language Runtime ( CLR ). The Mono C# compiler was started by Miguel de Icaza.

Is the interpret in mono source code obsolete?

Rahman M. (2012). Understanding Mono C# Compiler. This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL) Designer and Architect. the interpret in mono source code is obsolete,what's a pity, and i know it's even not a stable and for business usage, yes ?


Video Answer


2 Answers

Mono's compiler is written in C#. You may want to read about compiler bootstrapping.

like image 186
TheNextman Avatar answered Oct 04 '22 14:10

TheNextman


You should be looking for .c files, instead of .cpp files: the mono runtime is written in C, not C++.

like image 43
lupus Avatar answered Oct 04 '22 15:10

lupus