[Mono-dev] gmcs and The Future

Mark Probst mark.probst at gmail.com
Wed Feb 4 11:14:09 EST 2009


On Wed, Feb 4, 2009 at 5:10 PM, Jb Evain <jb at nurv.fr> wrote:
>>  So I'm not expecting the C# compiler to output anything other than IL
>>  but just eliminate the calling overhead and not relying on the JIT to do
>>  the inlining.
>
> That's just not possible for a large majority of the cases, as it
> would cause a lot of access exceptions. You can't simply inline an
> instance method which reads a private field in its own type, inside
> another type for instance.

Apart from the fact that if you're inlining a method from a different
assembly by "importing" it you're not only depending on the interface
of the assembly not to change in the future, but also on the
implementation, which is a very bad idea.

Mark

-- 
Mark Probst
  http://www.complang.tuwien.ac.at/schani/
  http://www.flickr.com/photos/schani/
  http://schani.wordpress.com/


More information about the Mono-devel-list mailing list