Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cleanup: add PTR as an alias for I64 #8

Merged
merged 1 commit into from
Nov 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions examples/basic.zig
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ pub fn main() !void {
const man = .{ .wasm = &[_]manifest.Wasm{.{ .wasm_file = wasmfile_manifest }} };
var f = Function.init(
"hello_world",
&[_]sdk.c.ExtismValType{sdk.c.I64},
&[_]sdk.c.ExtismValType{sdk.c.I64},
&[_]sdk.c.ExtismValType{sdk.PTR},
&[_]sdk.c.ExtismValType{sdk.PTR},
&hello_world,
@constCast(@as(*const anyopaque, @ptrCast("user data"))),
);
Expand Down
2 changes: 2 additions & 0 deletions src/main.zig
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,5 @@ pub fn extismVersion() []const u8 {
const version = std.mem.span(c_version);
return version;
}

pub const PTR = c.I64;
Loading