Skip to content

Call __main_void if exported by a plugin.#500

Open
PiotrSikora wants to merge 2 commits intoproxy-wasm:mainfrom
PiotrSikora:main_void
Open

Call __main_void if exported by a plugin.#500
PiotrSikora wants to merge 2 commits intoproxy-wasm:mainfrom
PiotrSikora:main_void

Conversation

@PiotrSikora
Copy link
Member

This is how Rust exports main() function since Rust v1.67.

This is how Rust exports main() function since Rust v1.67.

Signed-off-by: Piotr Sikora <code@piotrsikora.dev>
Copy link
Contributor

@leonm1 leonm1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we include a test for this?

@PiotrSikora
Copy link
Member Author

Should we include a test for this?

Sure, I'll add it.

But we don't really have tests for any of the start functions here... and we have exactly zero integration tests with real SDKs in this repo, only plain Wasm modules... Maybe you have some cycles to add them?

Signed-off-by: Piotr Sikora <code@piotrsikora.dev>
@PiotrSikora
Copy link
Member Author

PiotrSikora commented Mar 2, 2026

Actually, this turns out to be tricky.

We need to use nightly channel (bazelisk --@rules_rust//rust/toolchain/channel=nightly) to build Wasm reactors, but this can be only done globally and not on a per-target basis, so adding this flag would also affect Wasmtime build... but since this would be limited only to builds within this repo and not affect embedders, perhaps that's fine?

But my vote would be to skip this test altogether, since we don't test the other entrypoints anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants