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

Extern macro CLI options for WASM boilerplate #200

Merged
merged 4 commits into from
Jul 26, 2023

Conversation

rooooooooob
Copy link
Collaborator

Extern macro CLI option for WASM boilerplate

This will help compatibility for CML and make changing any details of
these only require changing those macros instead of needing to
regenerate the library again.

This also significantly decreases the amount of repetitive boilerplate
junk making reading the files clearer.

--wasm-cbor-json-api-macro

Override for the CBOR to/from bytes API + to/from JSON

--wasm-conversions-macro

Override for the conversion traits between wasm/rust types. (e.g. From
between them + AsRef for the rust one)

* --wasm-cbor-json-api-macro

Override for the CBOR to/from bytes API + to/from JSON

* --wasm-conversions-macro

Override for the conversion traits between wasm/rust types. (e.g. From
between them + AsRef for the rust one)

This will help compatibility for CML and make changing any details of
these only require changing those macros instead of needing to
regenerate the library again.

This also significantly decreases the amount of repetitive boilerplate
junk making reading the files clearer.
@rooooooooob
Copy link
Collaborator Author

This is kind of like what we had in CSL with to_from_bytes!(WasmTypeHere); but with more functionality and integrated into cddl-codegen.

@rooooooooob rooooooooob added the Quality-of-life feature Feature that helps, but is outside of the CDDL specification label Jul 25, 2023
@gostkin
Copy link
Contributor

gostkin commented Jul 26, 2023

@rooooooooob could you pls fix the pipeline as well?

@rooooooooob
Copy link
Collaborator Author

@gostkin I can try. I looked into it a few days ago but it's coming from our dependencies. It was failing before this PR. I don't get it locally so I'm guessing it's different versions of the dependencies/subdependencies or something.

@rooooooooob rooooooooob merged commit 0469793 into master Jul 26, 2023
@rooooooooob rooooooooob deleted the extern-struct-macros branch July 26, 2023 18:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Quality-of-life feature Feature that helps, but is outside of the CDDL specification
Projects
Development

Successfully merging this pull request may close these issues.

2 participants