cyber icon indicating copy to clipboard operation
cyber copied to clipboard

Feature request: expose a zig module

Open rockorager opened this issue 1 year ago • 3 comments

I was curious if you would accept exposing a zig module for cyber so it could be imported directly in a zig project without going through the c api?

rockorager avatar Aug 03 '24 14:08 rockorager

This seems like a duplicate of https://github.com/fubark/cyber/issues/86.

sno2 avatar Aug 03 '24 22:08 sno2

@sno2 Isn't that specifically about tooling?

But I concur, having a direct Zig API would be very much appreciated!

TheOnlySilverClaw avatar Nov 28 '24 18:11 TheOnlySilverClaw

I have started to improve capi.zig, so you can expect something in the next commit. But it's not comprehensive, I've only included things I've needed to use for testing. It's essentially a wrapper over the the flat C functions as Zig methods.

Edit: Actually it's already there. If you're unsure of how to use it I would just do a grep for usages. For example ZVM is the Zig wrapper for VM. But there is no Zig module for it, if someone is interested I'd welcome the PR.

fubark avatar Dec 10 '24 12:12 fubark