Skip to content

Why do we depend on wit-bindgen as a regular dependency #827

@briansmith

Description

@briansmith

My understanding is that wit-bindgen generates Rust code at build time. My understanding is that the generated code will basically never change in a substantial way because the ABIs for wasip2 and wasip3 pretty much mandate what is generated? Maybe this is less true for wasip3 than for wasip2 since wasip3 is less stable.

So, why not just generate that code and then check the generated code into getrandom, bypassing the wasip2 and wasip3 crates and all their dependencies?

I remember that we've avoided depending on windows-sys because it causes problems exactly analogous to the problems we're experiencing with wasip2 and wasip3 targets, and the solution for Windows is basically what I'm suggesting here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions