In article <e0qq49$2j9$1 at digitaldaemon.com>, Johan Granberg says... > widgets[$-1]=new Widget("exit button",p,window,input,&exitfunk); >is this expected behavior with delegate and inner functions or is it a bug? You are storing a reference to a local variable.