[Mono-devel-list] inheriting from System.Delegate - how?

David Jung jungdl at ornl.gov
Fri Feb 27 11:40:44 EST 2004


I'm writing an interpreter for a .NET hosted language that includes a 
kind of
function-pointer like construct that I want to expose as delegates to .NET.

According to MS's documentation for the System.Delegate class:
"However, only the system and compilers can derive explicitly from the 
*Delegate* class or from the MulticastDelegate 
<http://msdn.microsoft.com/library/en-us/cpref/html/frlrfsystemmulticastdelegateclasstopic.asp> 
class."
Any idea how exactly?  When I try it I get an error from mcs 0.30:
error CS0644: `bilab.Func' cannot inherit from special class 
`System.Delegate'

Is there some switch/define/attribute or something that will allow me to 
do it?
How does mcs do it? (or doesn't it).

Any help appreciated.  Thanks,
-David.





More information about the Mono-devel-list mailing list