[Mono-list] System.Text.RegularExpressions

Miguel de Icaza miguel@ximian.com
31 Jan 2002 17:53:56 -0500


> > Hmmm... I never really thought about that. I don't know a lot about the
> > security architecture, could you give me an example of how to turn off this
> > permission? I'll test it against the MS implementation first, but my guess is
> > that CIL compilation won't work in this case, and you'll have to resort to the
> > default (interpreted) behaviour.
> 
> I didn't research the details, yet. It was just a heads up; if you plan
> to keep the interpreter support that's good enough to workaround the
> issue if it ever arises.

Oh.  I did not understand initially.  So the CIL compilation will be a
future optimization. 

In that case, before choosing to use CIL, you could always do something
like:

ModuleBuilder GetModuleBuilder ()
{
	try {
		mb = ...DefineDynamicModule ();
	} catch (SecurityException){
		return null;
	}
	return mb;
}

miguel