Stream: general

Topic: witx-bindgen


view this post on Zulip Léo Gaspard (Jan 07 2021 at 02:00):

Edit: I was asking where witx-bindgen was living, and obviously I thought of doing a github-wide search only just after searching, so... Just found it's in bytecodealliance/wasi

view this post on Zulip Léo Gaspard (Jan 07 2021 at 02:20):

Actually, reusing this topic for an actual question... Is it known that witx-bindgen is broken? I've got a function that takes in (array u8), and witx-bindgen generates a function that takes &'a [u8] (instead of &mut [u8]) and does not declare the 'a lifetime

view this post on Zulip Andrew Brown (Jan 07 2021 at 17:14):

I just upgraded witx-bindgen to the latest version of witx, which fixes the CI: https://github.com/bytecodealliance/wasi/pull/56

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

view this post on Zulip Andrew Brown (Jan 07 2021 at 17:14):

@Pat Hickey or @Alex Crichton, can you take a look?

view this post on Zulip Andrew Brown (Jan 07 2021 at 17:15):

@Léo Gaspard, for the lifetime issue you bring up, is it the same as https://github.com/bytecodealliance/wasi/issues/47?

In wasi-nn, the API passes pointers into several functions: in set_input a tensor structure is passed in in get_output a pointer to a buffer and its max length are passed in to receive the copied o...

view this post on Zulip Andrew Brown (Jan 07 2021 at 17:16):

@Alex Crichton, that was fast :smile:

view this post on Zulip Pat Hickey (Jan 07 2021 at 17:20):

thanks, idk why that broke CI, do you mind pointing me to the failure?

view this post on Zulip Pat Hickey (Jan 07 2021 at 17:20):

id like to make sure when i do a witx release in the future i dont break it, or i fix it myself :)

view this post on Zulip Pat Hickey (Jan 07 2021 at 17:22):

found https://github.com/bytecodealliance/wasi/pull/55/checks but it doesnt make sense to me :/ version 0.8.7 should have been available on crates.io still...

Disclaimer: this is a via-github en-passant PR, nothing is actually tested but hopefully it'll add the repository link to crates.io so other people don't have to also use the github search ...

view this post on Zulip Andrew Brown (Jan 07 2021 at 17:38):

hm... perhaps it was that the Git submodule was looking at an old version of witx?

view this post on Zulip Andrew Brown (Jan 07 2021 at 17:38):

it's a local path dependency, not a crates.io dependency

view this post on Zulip Pat Hickey (Jan 07 2021 at 17:58):

hmm, yeah, so the cargo.toml didnt agree with the path dependency prior to that CI run

view this post on Zulip Pat Hickey (Jan 07 2021 at 17:58):

im not sure how that got introduced without CI catching it

view this post on Zulip Pat Hickey (Jan 07 2021 at 17:59):

could have been a lot of things, the submodule hadnt been updated since feb 2020. hopefully this doesnt happen again. thanks!

view this post on Zulip Léo Gaspard (Jan 07 2021 at 18:44):

@Andrew Brown I don't think so, I've submitted issue 57 with a simple reproducer :)


Last updated: Nov 22 2024 at 16:03 UTC