This week, there was some discussion about writing a Pascal Compiler on mono-devel-list. I'm not getting into the "political" debates here, but lemme post a few thoughts about the technical point of view.
First of all, writing a compiler isn't something you can do in a week or two. It's been almost two years now since I started working on GMCS - and I had an already existing and fairly stable codebase (MCS) to start with. You Pascal guys will probably start from scratch. So it doesn't hurt doing some careful planning and discussion first. Having a concrete roadmap may also help getting other people interested in the project.
There are two fundamentally different approaches on writing a new Pascal Compiler:
I have no idea whether the first idea is feasible or not, so lemme just post a few thoughts about the second one.
At the moment, we already have three compilers:
Speaking of GMCS, there are four main tasks which I'm planning to finish till May if everything works fine:
Once these tasks are done, GMCS should be ready to become our new production compiler.
After that, we should try to figure out how much the VB.NET guys needed to change from GMCS's original code base and what these changes are. Maybe it's possible to make a part of GMCS a library and share this between the two compilers. I could imagine that we can reuse large parts of GMCS without many modifications, for instance its type lookup system etc.
Such a library could also benefit any new compiler projects like a Pascal compiler - you could use that library, write a parser for your new language and do some language-specific modifications.
This week was a really good hacking week for me. I made good progress with Nullable Types and also found the time to do some general GMCS bug fixing. It's really cool that people are now actually using GMCS to compile their applications and file bug reports. The whole generics code is now fairly stable and almost ready for prime time, but I still need more bug reports ....
Regarding Nullable Types, I implemented lifted conversions and lifted operators (unary and binary so far). This means that you can use the "normal" (builtin and user-defined) operators with nullable types:
This will return null if either a or b is null.
Next are comparisions with null values, for instance
I'll also do some more bug fixing next week.