-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
enhancementNew feature or requestNew feature or requestquestionFurther information is requestedFurther information is requested
Description
As reported in https://zigforum.org/t/zig-nestedtext-release-0-1-0/383/17:
test "typed parse: jeang3nie" {
const Kind = union(enum) {
color: []const u8,
plain,
};
var p = Parser.init(testing.allocator, .{});
const r = try p.parseTyped(Kind, "> null");
defer p.parseTypedFree(r);
std.debug.print("{s}\n", .{r});
}This parses into color with the string null since this is the first field that succeeds, but parsing as a string should probably be the last resort (since this will always succeed).
nfisher1226
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestquestionFurther information is requestedFurther information is requested