code: function mergeReferences (oldRefs, newRefs) {
      const _newRefs = _(newRefs);
  
      return _(oldRefs)
          .reject(function (oldRef) {
              return _newRefs.any(function (newRef) {
                  return matches(oldRef, newRef);
              });
          })
          .concat(newRefs)
          .uniq()
          .sort()
          .value();
  }
docs: Merge new references with old references; ignore old references from the same file.