How to determine whether two variables refer to the same object

question

#1

I have been googling for half an hour with no luck. In python, a is b can check whether a and b refer to the same object. What’s the counterpart in julia?


#2
help?> ===
search: === == .== !==

  ===(x,y) -> Bool
  ≡(x,y) -> Bool

  Determine whether x and y are identical, in the sense that no program could
  distinguish them. Compares mutable objects by address in memory, and
  compares immutable objects (such as numbers) by contents at the bit level.
  This function is sometimes called egal.

  julia> a = [1, 2]; b = [1, 2];

  julia> a == b
  true

  julia> a === b
  false

  julia> a === a
  true

#3

Thank you. Very useful.