atom-julia-client icon indicating copy to clipboard operation
atom-julia-client copied to clipboard

Multiline array assignments

Open BeastyBlacksmith opened this issue 7 years ago • 2 comments

The following code gives a syntax error, when hitting cmd+enter at the first line:

a = [ 1,
      2
]

BeastyBlacksmith avatar Feb 28 '18 12:02 BeastyBlacksmith

Try

a = [ 1,
      2
    ]

instead -- Juno's block finding is indentation based.

pfitzseb avatar Feb 28 '18 13:02 pfitzseb

Just adding some more context about the way this is parsed:

for now our block finding doesn't look at the code at all and only cares about the indentation which is simple and robust, but obviously fails in cases like this one

It's parsed by whitespace for now.

NHDaly avatar Nov 05 '18 15:11 NHDaly