Re: public, static & friends
Posted: Sat Feb 09, 2008 12:32 pm
Can you reply again and use the "Upload attachment" to give us your source?
Discussion about the Cobra programming language.
http://cobra-language.com/forums/
RichS wrote:It seems the property must be shared as well.
Try sharing both definitions.
(Chuck, I'll upload the source when I find the right button.)
print x.lista
var _name as String is public
class Bob
shared
var _classVariable as String is public
var _instanceVariable as String? is public
class Program
def main is shared
Bob._classVariable = "Yo"
a = Bob()
a._instanceVariable = "baby"
b = Bob()
b._instanceVariable = "and then some more"
print Bob._classVariable
print a._instanceVariable
print b._instanceVariable