The stately := operator feature proposal

Geancarlo Rocha asdf at mailinator.com
Thu May 30 10:12:25 PDT 2013


On Thursday, 30 May 2013 at 15:05:40 UTC, monarch_dodra wrote:
> I could be mistaken, but those languages don't have the notion 
> of declaration, do they? (honest question)
>
> Last time I tried a similar language, basically, any variable 
> name that is not yet used is resolved to null. Which is why the 
> syntax work.
>
FYI:

MATLAB:

>> x = linspace(0, 2*pi, 1000);
y = sin(x);
plot(x, y)
>> disp(z)
??? Undefined function or variable 'z'.


Python(IDLE):

>>> print x

Traceback (most recent call last):
   File "<pyshell#0>", line 1, in <module>
     print x
NameError: name 'x' is not defined


More information about the Digitalmars-d mailing list