[IronPython] Plans for overloads?

Jonathan Jacobs korpse-ironpython at kaydash.za.net
Wed Jul 20 19:06:22 CEST 2005


Keith J. Farmer wrote:
> Illustrating my concern with indexers:
> 
> delegate Foo DelegateType();
> public static DelegateType this (Type type) { }
> public Foo<T>() { }
> 
> x = Foo[typeof(int)]() .. is ambiguous.  You can't determine if you've
> called the constructor, or if you've called the static indexer, passing
> in the int type, and then executing the delegate returned to get a Foo
> object to store in x.

I now understand your concern better, unfortunately I'm not C# guru :-( 
  (I hadn't even touched the language up until a few weeks ago.) I can't 
get your code, as is, to compile, would you mind providing a more 
complete example?

--
Jonathan



More information about the Ironpython-users mailing list