adt.js
function (that) {
      var ctr = this.constructor;
      if (this === that) return true;
      if (!(that instanceof ctr)) return false;
      var names = ctr.__names__;
      var i = 0, len = names.length;
      var vala, valb, n;
      for (; i < len; i++) {
        n = names[i], vala = this[n], valb = that[n];
        if (vala instanceof adt.__Base__) {
          if (!vala.equals(valb)) return false;
        } else if (!adt.nativeEquals(vala, valb)) return false;
      }
      return true;
    }
function (that) {
      var ctr = this.constructor;
      if (this === that) return true;
      if (!(that instanceof ctr)) return false;
      var names = ctr.__names__;
      var i = 0, len = names.length;
      var vala, valb, n;
      for (; i < len; i++) {
        n = names[i], vala = this[n], valb = that[n];
        if (vala instanceof adt.__Base__) {
          if (!vala.equals(valb)) return false;
        } else if (!adt.nativeEquals(vala, valb)) return false;
      }
      return true;
    }
function ( that ) { var ctr = this . constructor ; if ( this === that ) return true ; if ( ! ( that instanceof ctr ) ) return false ; var names = ctr . __names__ ; var i = 0 , len = names . length ; var vala , valb , n ; for ( ; i < len ; i ++ ) { n = names [ i ] , vala = this [ n ] , valb = that [ n ] ; if ( vala instanceof adt . __Base__ ) { if ( ! vala . equals ( valb ) ) return false ; } else if ( ! adt . nativeEquals ( vala , valb ) ) return false ; } return true ; }
Recursively compares all adt.js types, delegating other JS values to `adt.nativeEquals`.
Recursively compares all adt . js types delegating other JS values to adt . nativeEquals .