static bool CompareRef(JSBaseRef a, JSBaseRef b) { if (System.Object.ReferenceEquals(a, b)) { return(true); } object l = a; object r = b; if (l == null && r != null) { return(b.reference <= 0); } if (l != null && r == null) { return(a.reference <= 0); } if (a.reference != b.reference) { return(false); } return(a.reference > 0); }
public override bool Equals(object o) { if (o == null) { return(reference <= 0); } JSBaseRef lr = o as JSBaseRef; if (lr == null || lr.reference != reference) { return(false); } return(reference > 0); }
public void Push(JSBaseRef reference) { }