[chuck-users] Static bug
signal.automatique at gmail.com
Tue Nov 24 17:09:22 EST 2009
2009/11/24 Hans Aberg <haberg at math.su.se>
> For some reason, 'chuck' does not instantiate class static constants until
> there has been an instantiation of the class itself.
Writing the value to the variable is deemed part of the constructor instead
of the instantiation.
You could get around this using a static member function to set all such
values, that way you could have static members set to default values without
a class instance.
I'm not completely happy with the current behaviour as two elements of a
single line are treated in very different ways without this being
intuitively clear. Of course it could be argued that if this bothers us we
simply shouldn't do it.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the chuck-users