Why not "hello" === "hello"?

question

#1

I understand that strings are implemented as mutable types. But from a user’s perspective, strings are values, like integers are. Currently "hello" === "hello" returns false, but if it returned true, then things like these:

would be automatically fixed.


#2

That’s why. I might be fixed in the future but it has never been the case so no one should be relying on it.


#3

Also, it’ll not be an automatic fix. The generic fix is still https://github.com/JuliaLang/julia/issues/4648


#4

You mean that a “patch” cannot be made for strings, so that === deviates from its general behavior and actually does the same as ==, only for strings?