Benjamin West wrote:
> http://www.codeplex.com/IronPython/WorkItem/View.aspx?WorkItemId=6014
>
> Anyone have guidelines on avoiding this kind of thing, or if there is
> a fix that will make this a non-issue?
>   

Hmm... well the super call isn't necessary with Form and __init__. Does 
that help?

Michael
http://www.voidspace.org.uk/ironpython/index.shtml

> -Ben
>
> codeplex butchers the white space:
>
> import clr
> clr.AddReference("System.Windows.Forms")
> from System.Windows.Forms import *
>
> class DefaultForm(Form):
>   def __init__(self, *args, **kwds):
>     super(type(self), self).__init__(*args, **kwds)
>     self.test = "Default Stuff"
>
> class AppForm(DefaultForm):
>   def __init__(self, *args, **kwds):
>     super(type(self), self).__init__(*args, **kwds)
>     self.test = "real Stuff"
>
> if __name__ == '__main__':
>   # does not cause stack overflow
>   #f = DefaultForm()
>
>   # causes stack overflow.
>   f = AppForm()
>   Application.Run(f)
> _______________________________________________
> users mailing list
> [email protected]
> http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
>
>   

_______________________________________________
users mailing list
[email protected]
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com

Reply via email to