Aliases for `=` and `==`

I meant more specifically in this case, there is a particular syntactic pattern that exhibits the problem this issue is about. We can look at some code (e.g. the General registry) to see how often that pattern appears.

It’s clearly a waste of time to look into this: I’m guessing the probability that this will ever change in Julia is nil, as most users are happy with the current syntax and the benefits of making a change are very limited

7 Likes

I am still not sure what the purpose of this exercise is — the pattern is problematic only if it is a bug, and presumably it isn’t, for any package with decent test coverage.

Generally there is a trade-off between languages protecting users from mistakes like this (via type checks, making certain syntaxes error, etc) and having terse syntax. Though this is not made very explicit, Julia is somewhere in the middle of this spectrum: ambiguous syntax is usually an error, but other than that the language does not try to second-guess the programmer.

I happen to like Julia this way, but I understand that reasonable people can have a different preference about this. It’s just that, as @dlfivefifty suggested, surface syntax is very unlikely to change in Julia.

The idea would be to count the intended == version as a proxy for the buggy = version. But as you say, it’s probably not worthwhile.