It's a matter of taste – and the fact that we wanted Julia to feel familiar in particular to Matlab users (and to a lesser extent Ruby users). I personally don't like significant indentation. It gets really awkward and fiddly when you're trying to cut and paste into a terminal or into an editor. I've seen a significant number of live Python demos flounder as the presenter struggled with indentation issues. It feels to me like Python programs trail off into space with never-ending scopes. Jeff and Viral both happen to feel similarly, so Julia ended up looking more like Matlab than like Python.
On Thu, May 15, 2014 at 3:04 PM, Dustin Lee <qhf...@gmail.com> wrote: > Thanks. I should probably have been more clear. I understand what it > *is* doing. I'm just curious if there was a reason besides "taste" to > choose that over whitespace significance. > > > On Thursday, May 15, 2014 12:55:07 PM UTC-6, Stefan Karpinski wrote: > >> The `end` keyword closes blocks. Python uses indentation for this. In >> Julia indentation is not significant. >> >> >> On Thu, May 15, 2014 at 2:51 PM, Dustin Lee <qhf...@gmail.com> wrote: >> >>> Coming from python I've found that julias's "end" statement doesn't >>> bother me as much as I would have thought, but when I show some code to my >>> python colleagues this really annoys them. But this got me thinking, what >>> *is* the purpose of "end". Is it just a taste issue, a way to make parsing >>> easier, something else? >>> >>> My make believe answer that I found myself starting to make to my >>> colleagues was that it was for ease of writing a parser, but then I wasn't >>> sure how this squares with the fact that languages like python and haskell >>> don't seem to have too much trouble w/out braces or end keywords. >>> >>> Just curious, >>> >>> dustin >>> >> >>