code: function getCanonicalPath(path) {
          path = path.replace(/\//g, '\\');
          path = path.replace(/\\\\/g, '\\');
          return path;
      }
docs: Returns the canonical Windows path for a given path. This means
  basically replacing any forwards slashes with backslashes.
  
  @param path  the path whose canonical form to return