[Mono-devel-list] Suggestion for mcs

Andreas Nahr ClassDevelopment at A-SoftTech.com
Tue Mar 16 16:20:19 EST 2004


today I stumbled about a simple 'problem'.
If you compile an assembly all constants have to be inlined by the compiler (AFAIR this is even a spec requirement).
After this step constants which are internal or private should not be referable from outside of the assembly. So shouldn't it be possible to entirely remove them?
Would probably not boost speed but save some bytes of memory in the IL-file (perhaps we even gain a tiny little bit of speed because of the smaller assemblies).

At least it would be nice to have a compiler switch to do this. IMHO this would be quite useful for some programs that prevent magic numbers by using e.g. consts at the top of a class file (this, however, isn't really true for most parts of mono)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20040316/ee6c376c/attachment.html 

More information about the Mono-devel-list mailing list