The return value will contain strings pointing into the original text.
Each component that is provided will be non-null.
pub fn parse(text: []const u8) ParseError!Uri
pub fn parse(text: []const u8) ParseError!Uri {
const scheme, const rest = std.mem.cutScalar(u8, text, ':') orelse
return error.InvalidFormat;
if (!isValidScheme(scheme))
return error.UnexpectedCharacter;
return parseAfterScheme(scheme, rest);
}