yurydelendik opened PR #1275 from embed-c-doc
to master
:
This is a simple example, taken for wasm-c-api, that explains step-by-step how to embed wasmtime via C API. Provided simple bash steps using Clang for Linux too. Maybe it is temporary solution by better than "... more coming soon" at this moment.
sunfishcode submitted PR Review.
sunfishcode created PR Review Comment:
Nit: When we refer to Wasmtime and we're not talking about the crate name or CLI binary name, we capitalize Wasmtime.
sunfishcode submitted PR Review.
sunfishcode created PR Review Comment:
Is there a way we can avoid embedding the version number here? Otherwise, we'll have to remember to keep this up to date as we publish new versions.
sunfishcode created PR Review Comment:
We should mention the
own
macro for people not familiar with the convention. Maybe "own
is a macro that doesn't actually do anything, but helps document which pointers "own" the resources associated with the objects they point to" or so.
sunfishcode created PR Review Comment:
"By the host" makes it a little unclear who's actually providing it. Wording suggestion: "The WebAssembly module has an import,
"hello"
, which we'll provide for it though the embedding API.
alexcrichton submitted PR Review.
alexcrichton created PR Review Comment:
FWIW I'd recommend just not using it entirely in the introductory documentation. It feels like an unnecessary speed bump that otherwise can be explained later.
alexcrichton submitted PR Review.
alexcrichton created PR Review Comment:
I think it might be best to inline all the code here in this document rather than linking externally, because this external link could change or otherwise go away.
alexcrichton created PR Review Comment:
Could this explain that internally a
wasm_byte_vec_t
is just a pointer/length?
alexcrichton submitted PR Review.
alexcrichton created PR Review Comment:
I think it might be good to detail what's necessary for Linux/macOS/Windows since they're all pretty similar and would be good to have intro docs for developers on these platforms.
alexcrichton created PR Review Comment:
Additionally could dynamic linking be covered as well?
alexcrichton created PR Review Comment:
My style may be somewhat different but I personally prefer code listings where everything is presented as one copy-pastable block rather than multiple snippets with explanations inbetween. The explanations can always be through comments as well in the code, and I think it's best to have compiling and working examples in the documentation wherever we can.
yurydelendik updated PR #1275 from embed-c-doc
to master
:
This is a simple example, taken for wasm-c-api, that explains step-by-step how to embed wasmtime via C API. Provided simple bash steps using Clang for Linux too. Maybe it is temporary solution by better than "... more coming soon" at this moment.
alexcrichton edited PR #1275 from embed-c-doc
to main
:
This is a simple example, taken for wasm-c-api, that explains step-by-step how to embed wasmtime via C API. Provided simple bash steps using Clang for Linux too. Maybe it is temporary solution by better than "... more coming soon" at this moment.
yurydelendik closed without merge PR #1275.
Last updated: Dec 23 2024 at 12:05 UTC