code: function _joinAndCanonicalizePath(parts) {
      var /** @type {?} */ path = parts[_ComponentIndex.Path];
      path = path == null ? '' : _removeDotSegments(path);
      parts[_ComponentIndex.Path] = path;
      return _buildFromEncodedParts(parts[_ComponentIndex.Scheme], parts[_ComponentIndex.UserInfo], parts[_ComponentIndex.Domain], parts[_ComponentIndex.Port], path, parts[_ComponentIndex.QueryData], parts[_ComponentIndex.Fragment]);
  }
docs: Takes an array of the parts from split and canonicalizes the path part
  and then joins all the parts.
  @param {?} parts
  @return {?}