结构相等符 == 被用来判断两个值是否相等。而引用相等 === 用来检查两个引用是否具有同一性,即是否指向同一个对象。
==
===
1234567
class A { var p = 0}var a = A()var b = aprint(b == a)
参考自:Ray Wenderlich - iOS11 by Tutorials
Luyuan Wang
Empty Stack Engineer
Beijing
Posts
107
Categories
0
Tags
64
Update your browser to view this website correctly. Update my browser now
×