Highest Rated Comments


forsakenquantum2 karma

I think the two main things I ran into were 1) if I declared variables at the top level in a script that wasn't wrapped in a module and then tried to change them in a for loop, the changes wouldn't hold after exiting the for loop, and 2) it seemed like I had a similar problem inside a function, where a variable declared outside a for loop couldn't be modified by it. The first one was frustrating but at least I could work around it by wrapping things at the top level in a module, but the second one was confusing as to why it was happening and how to fix it.

forsakenquantum1 karma

I'm really excited about the possibilities of Julia and have used it in several projects. I find I end up going back to Python often, though, because I find the scoping rules in Julia to be pretty confusing and difficult to debug when something is wrong. Are you committed to the current way of scoping, and if so, why do you think it's best?