Simple function to make a supersede the properties between two objects.
The properties into the same.
173095
function supersede(target, source, force, deepStringMixin) {
    if (source) {
        eachProp(source, function (value, prop) {
            if (hasProp(target, prop)) {
                if (deepStringMixin && typeof value === 'object' && value && !isArray(value) && !isFunction(value) && !(value instanceof RegExp)) {

                    if (!target[prop]) {
                        target[prop] = {};
                    }
                    supersede(target[prop], value, force, deepStringMixin);
                } else {
                    target[prop] = value;
                }
            }
        });
    }
    return target;
}
428233
function(source, obj, override) {
      var out;

      // Create extensible object.
      if(override) {
        out = source;
      } else {
        // Create shallow copy of source.
        out = {};
        for(var i in source){
          if(source.hasOwnProperty(i)) {
            out[i] = source[i];
          }
        }
      }

      // Copy properties.
      for(var j in obj) {
        if(obj.hasOwnProperty(j)) {
          out[j] = obj[j];
        }
      }

      return out;
    }
383885
function extendProperties (dest, source, isObjectBased) {
  var key;
  if (isObjectBased && source.constructor === Object) {
    for (key in source) {
      if (source[key] === undefined) { continue; }
      if (source[key] && source[key].constructor === Object) {
        dest[key] = utils.clone(source[key]);
      } else {
        dest[key] = source[key];
      }
    }
    return dest;
  }
  return source;
}
522117
function(setA, setB, property1, property2){
	// p for param
	// v for value
	var numProps = numericProperties(setA, setB, property1, property2);
	var sAv1 = numProps.sAv1,
		sAv2 = numProps.sAv2,
		sBv1 = numProps.sBv1,
		sBv2 = numProps.sBv2,
		count = sAv2 - sAv1 + 1;

	var after = {
		difference: [sBv2+1, sAv2],
		intersection: [sAv1,sBv2],
		union: [sBv1, sAv2],
		count: count,
		meta: "after"
	};
	var before = {
		difference: [sAv1, sBv1-1],
		intersection: [sBv1,sAv2],
		union: [sAv1, sBv2],
		count: count,
		meta: "before"
	};

	// if the sets are equal
	if(sAv1 === sBv1 && sAv2 === sBv2) {
		return {
			intersection: [sAv1,sAv2],
			union: [sAv1,sAv2],
			count: count,
			meta: "equal"
		};
	}
	// A starts at B but A ends later
	else if( sAv1 === sBv1 && sBv2 < sAv2 ) {
		return after;
	}
	// A end at B but A starts earlier
	else if( sAv2 === sBv2 && sBv1 > sAv1 ) {
		return before;
	}
	// B contains A
	else if( within(sAv1, [sBv1, sBv2]) && within(sAv2, [sBv1, sBv2]) ) {
		return {
			intersection: [sAv1,sAv2],
			union: [sBv1, sBv2],
			count: count,
			meta: "subset"
		};
	}
	// A contains B
	else if( within(sBv1, [sAv1, sAv2]) && within(sBv2, [sAv1, sAv2]) ) {
		return {
			intersection: [sBv1,sBv2],
			// there is a difference in what A has
			difference: [null, null],
			union: [sAv1, sAv2],
			count: count,
			meta: "superset"
		};
	}
	// setA starts earlier and overlaps setB
	else if(sAv1 < sBv1 && within(sAv2, [sBv1, sBv2]) ) {
		return before;
	}
	// setB starts earlier and overlaps setA
	else if(sBv1 < sAv1 && within(sBv2, [sAv1, sAv2]) ) {
		return after;
	}
	// side by side ... nothing intersection
	else if(sAv2 === sBv1-1) {
		return {
			difference: [sAv1,sAv2],
			union: [sAv1, sBv2],
			count: count,
			meta: "disjoint-before"
		};
	}

	else if(sBv2 === sAv1 - 1) {
		return {
			difference: [sAv1,sAv2],
			union: [sBv1, sAv2],
			count: count,
			meta: "disjoint-after"
		};
	}
	if(!isNaN(count)) {
		return {
			count: count,
			meta: "disjoint"
		};
	}

}
687594
def union_update(self, other, ignore_conflicts=False):
        """"""
        if not ignore_conflicts:
            ensure_compatible(self, other)
        self._objects |= other._objects
        self._properties |= other._properties
        self._pairs |= other._pairs
379516
function push(obj, prop, value) {
    (obj[prop] = (obj[prop] || [])).push(value);
  }
1241213
function extend(object, properties) {
  object = object || { };
  const anotherObject = properties || { };

  for (const key in anotherObject) {
    const val = anotherObject[key];

    if (val || (val === '')) {
      object[key] = val;
    }
  }
  return object;
}
1373772
function merge(o) {
  if (!isPlainObject(o)) { return {}; }
  var args = arguments;
  var len = args.length - 1;

  for (var i = 0; i < len; i++) {
    var obj = args[i + 1];

    if (isPlainObject(obj)) {
      for (var key in obj) {
        if (hasOwn(obj, key)) {
          if (isPlainObject(obj[key])) {
            o[key] = merge(o[key], obj[key]);
          } else {
            o[key] = obj[key];
          }
        }
      }
    }
  }
  return o;
}
1131764
function mixin(inObj/*, inProps, inMoreProps, ...*/) {
    var obj = inObj || {};
    for (var i = 1; i < arguments.length; i++) {
      var p = arguments[i];
      try {
        for (var n in p) {
          copyProperty(n, p, obj);
        }
      } catch(x) {
      }
    }
    return obj;
  }
640040
function(a, b, aParent, bParent, prop, compares, options){
	var subsetCheck;
	if( !(prop in aParent)) {
		subsetCheck = "subsetB";
	} else if(prop in bParent){
		// property in a and b and not the same
		return false;
	}
	if( !(prop in bParent) ) {
		subsetCheck = "subsetA";
	}
	if(subsetCheck === "subsetB") {
		options.result[prop] = b;
	} else {
		options.result[prop] = a;
	}
	return undefined;
}
291739
function(propertyA, propertyB, opts) {
  opts = opts || {}
  const typeA = identify(propertyA);
  const typeB = identify(propertyB);

  // Simple value comparison
  if (typeA === types.string || typeA === types.number || typeA === types.boolean || typeA === types.function) {
    return propertyA === propertyB;
  }
  else if (typeA === types.array) {
    return propertyA.sort().toString() === propertyB.sort().toString();
  }
  else if (typeA === types.date) {
    return propertyA.valueOf() === propertyB.valueOf();
  }
  else if (typeA === types.object) {
    return compareObjectWithKeys(propertyA, propertyB)
  }
  else if (typeA === types.class) {
    if (opts.classComparator) {
      opts.classComparator(propertyA, propertyB);
    } else if (propertyA.constructor.name !== propertyB.constructor.name) {
      return false;
    }
    return compareObjectWithKeys(propertyA, propertyB)
  }
  return typeA === typeB;
}
16413
function() {
    var extended = {},
        deep     = false,
        i        = 0,
        length   = arguments.length;

    if (Object.prototype.toString.call(arguments[0]) === '[object Boolean]'){
      deep = arguments[0];
      i++;
    }

    var merge = function(obj) {
      for (var prop in obj) {
        if (Object.prototype.hasOwnProperty.call(obj, prop)) {
          if (deep && Object.prototype.toString.call(obj[prop]) === '[object Object]') {
            extended[prop] = window.AB.extend(true, extended[prop], obj[prop]);
          } else {
            extended[prop] = obj[prop];
          }
        }
      }
    };

    for (; i < length; i++) {
      merge(arguments[i]);
    }

    return extended;
  }
1170629
function(obj1, obj2){
                if(obj1 instanceof Array && obj2 instanceof Array){
                        if(obj1.length!==obj2.length){
                           return false;
                        }else{
                            for(var i=0; i<obj1.length; i++){
                                if(!this.objectSimilarity(obj1[i], obj2[i])){
                                    return false;
                                }
                            }
                        }
                }else if(obj1 instanceof Object && obj2 instanceof Object){
                    if(obj1!=obj2){
                        for(var j in obj2){
                            if(!obj1.hasOwnProperty(j)){
                                return false;
                            }
                        }
                        for(var k in obj1){
                            if(obj1.hasOwnProperty(k)){
                                if(obj2.hasOwnProperty(k)){
                                    if(!this.objectSimilarity(obj1[k], obj2[k])){
                                        return false;
                                    }
                                }else{
                                    return false;
                                }
                            }
                        }
                    }
                }else if(typeof(obj1)==="function" && typeof(obj2)==="function"){
                    if(obj1.toString()!==obj2.toString()){
                        return false;
                    }
                }else if(obj1!==obj2){
                    return false;
                }
                return true;
        }
130817
function diff(a, b) {
  var diff = {};
  var key;
  for (key in b) { if (b.hasOwnProperty(key) && b[key] !== a[key]) { diff[key] = b[key]; }}
  for (key in a) { if (a.hasOwnProperty(key) && !(key in b)) { diff[key] = undefined; }}
  return diff;
}
725012
function mergeDeepObjects(object1, object2) {
  const keys1 = Object.keys(object1);
  const keys2 = Object.keys(object2);

  let index = -1,
      mergedObject = {},
      key,
      indexOfKey;

  while (++index < keys1.length) {
    key = keys1[index];
    indexOfKey = keys2.indexOf(key);

    if (~indexOfKey) {
      mergedObject[key] = getDeeplyMergedValues(object1[key], object2[key]);

      keys2.splice(indexOfKey, 1);

      continue;
    }

    mergedObject[key] = object1[key];
  }

  if (keys2.length) {
    index = -1;

    while (++index < keys2.length) {
      key = keys2[index];

      mergedObject[key] = object2[key];
    }
  }

  return mergedObject;
}
1029615
function simpleMerge(target, source) {
  forEachProperty(source, function(val, key) {
    target[key] = val;
  });
  return target;
}
553530
function mergeDiff(a, diff) {
  var key, val;
  if (a && diff) {
    for (key in diff) { if (diff.hasOwnProperty(key)) {
      val = diff[key];
      if (val === undefined) {
        delete a[key];
      } else {
        a[key] = val;
      }
    }}
  }
  return a;
}