anchor.diff:      if (uri.hasAuthority != baseUri.hasAuthority) return uri;
       if (uri.hasAuthority) {
         if (uri.userInfo != baseUri.userInfo ||
  -      uri.host.toLowerCase() != baseUri.host.toLowerCase() ||
  -      uri.port != baseUri.port) {
  +          uri.host.toLowerCase() != baseUri.host.toLowerCase() ||
  +          uri.port != baseUri.port) {
           return uri;
         }
       }
   
  +    baseUri = baseUri.normalizePath();
       List<String> base = baseUri.pathSegments.toList();
  -    base = base.normalizePath();
       if (base.isNotEmpty) {
         base = new List<String>.from(base)..removeLast();
       }
  +    uri = uri.normalizePath();
       List<String> target = uri.pathSegments.toList();
  -    target = target.normalizePath();
       int index = 0;
       while (index < base.length && index < target.length) {
         if (base[index] != target[index]) {
  
positive.code:     }
      Uri packageLocation = packageMapping[packageName];
      if (packageLocation == null) {
        throw new ArgumentError.value(uri, "uri",
        "Unknown package name: $packageName");
      }
      return packageLocation.resolveUri(new Uri(path: rest));
    }
  
negative.code:       throw new ArgumentError.value(uri, "uri", "Must not have authority");
      }
      if (uri.path.startsWith("/")) {
        throw new ArgumentError.value(
            uri, "uri", "Path must not start with '/'.");
      }
      // Normalizes the path by removing '.' and '..' segments.
      uri = uri.normalizePath();
  