Skip to content

Conversation

ydnar
Copy link
Contributor

@ydnar ydnar commented Jun 18, 2023

Hi, thanks for writing this package. We’ve used it in production at Domainr for a long time. We’re in the midst of porting some of our infrastructure to WebAssembly + WASI, and wanted to contribute a patch.

This PR adds support for wasm + wasip1 builds in Go 1.21 via additional build tags.

  • The js build tag is used for legacy (browser) WebAssembly (GOARCH=wasm GOOS=js)
  • The wasip1 build tag is used for the new WASI Preview 1 in Go 1.21 (GOARCH=wasm GOOS=wasip1)

I took the liberty of renaming a couple files to better map their use (App Engine being one of many targets without mmap), and updated the doc comments.

Copy link
Owner

@oschwald oschwald left a comment

Choose a reason for hiding this comment

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

Nice. Thanks!

@oschwald oschwald merged commit 7d12b8c into oschwald:main Jun 18, 2023
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