What's the difference between “equal (=)” and “identical (==)” in ocaml?

后端 未结 4 898
慢半拍i
慢半拍i 2020-12-08 10:10

In OCaml, we have two kinds of equity comparisons:

x = y and x == y,

So what\'s exact the difference betw

4条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-12-08 10:49

    according to http://rigaux.org/language-study/syntax-across-languages-per-language/OCaml.html, == checks for shallow equality, and = checks for deep equality

提交回复
热议问题