[Mono-list] Implementing attribute-based code generation

Miguel de Icaza miguel@ximian.com
Thu, 13 Jan 2005 16:13:03 -0500


Hello,

> I couldn't tell from the website. Essentially, I am trying to add design 
> by contract support to the mono C# compiler (as an extension, rather 
> than a core patch to mcs). The best way to do this would seem to be to 
> have attributes that can modify methods. In other words:

In the past there was a modified C# compiler from a company (I believe
it was called XC#) that added preconditions to the language by injecting
stuff from the attributes into the code.

Nowadays you might want to look into Mono.Cecil and the work being done
at DNG by Jb Evain (see Monologue) for a tool that modified existing
assemblies and instruments them to have extra code (related to aspect
programming)