It doesn't require a smart lint program. It just needs Lint to have access 
to both the parse tree AND the original code (or code coordinate) that 
generates the parse tree. Right now Lint doesn't have access to the latter.

On Tuesday, May 19, 2015 at 8:54:10 PM UTC-4, Scott Jones wrote:
>
> Yes, the issue here is that a typo of accidentally forgetting or deleting 
> a single space, will lead you to a silent bug in your program... not very 
> good
> when you are trying to figure out just what is going wrong (especially if 
> your eyes are trained by years of C/C++/Java etc. to see all 3 of those
> cases as being equivalent!).
>
> This might be something that a smart lint program could/should catch... 
> generally, names with ! at the end are only used for functions that modify 
> their arguments,
> correct?  I wonder if a lint program could check to see if the RHS of an 
> assignment to a variable ending in !, without a space between the ! and =, 
> was some sort of function...
>
> -Scott
>
> On Tuesday, May 19, 2015 at 8:31:25 PM UTC-4, Yichao Yu wrote:
>>
>> On Tue, May 19, 2015 at 7:26 PM, Scott Jones <[email protected]> 
>> wrote: 
>> > a !=0     # checks if a is not == to 0 
>> > a!= 0     # sets a! to 0 
>> > a!=0      # checks if a is not == to 0 
>>
>> That's why we should always put spaces around `=`, `==`, `!=`. 
>>
>> > 
>> > 
>> > Spaces are very important in Julia! 
>> > 
>>
>

Reply via email to