[Gambas-user] Create Static and _call

Tobias Boege taboege at ...626...
Mon Jan 5 00:05:55 CET 2015


On Mon, 05 Jan 2015, Beno?t Minisini wrote:
> Le 04/01/2015 23:26, Tobias Boege a ?crit :
> > Hi Benoit,
> >
> > there is a behaviour which bothers me for some time. If I create a class
> > MyClass, make it Create Static and define a (non-static) Public Sub _call,
> > I cannot use
> >
> >    MyClass()
> >
> > The interpreter throws "MyClass._call is not static". I can still use
> >
> >    MyClass._call()
> >
> > but that doesn't look cool enough. Can the interpreter be made more clever
> > about this (or am I doing a forbidden thing)?
> >
> > Regards,
> > Tobi
> >
> 
> It's a bug. It's fixed in revision #6809.
> 

Works as far as the project I attached last time is concerned.

Attached now is a new version of the test project in which _call() has a
parameter. It fails here saying "wanted MyClass got Integer instead".

Regards,
Tobi

-- 
"There's an old saying: Don't change anything... ever!" -- Mr. Monk
-------------- next part --------------
A non-text attachment was scrubbed...
Name: create-static-call-0.0.2.tar.gz
Type: application/octet-stream
Size: 3926 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20150105/dca84276/attachment.obj>


More information about the User mailing list