Skip to content

Commit a535538

Browse files
Add example for lazy parser
. . .
1 parent d18df42 commit a535538

File tree

3 files changed

+127
-51
lines changed

3 files changed

+127
-51
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
[![parcom ci](https://github.com/dokwork/parcom/actions/workflows/ci.yml/badge.svg)](https://github.com/dokwork/parcom/actions/workflows/ci.yml)
44

55
> [!WARNING]
6+
> This library is underdeveloped. API is not stable.
7+
8+
> [!IMPORTANT]
69
> Required version of zig is 0.13.0
710
811
Parser combinators for Zig.

examples/expression.zig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ fn expr(alloc: std.mem.Allocator) !p.TaggedParser(Value) {
103103
.transform(Value, alloc, fns.calculate);
104104
};
105105

106-
return try sum.tagged(alloc);
106+
return try sum.taggedAllocated(alloc);
107107
}
108108

109109
fn evaluate(alloc: std.mem.Allocator, expression: []const u8) !?Value {

0 commit comments

Comments
 (0)