Skip to content

Fix Instance.GetMemories() ignored memories after the 1st non-memory export#326

Merged
jsturtevant merged 2 commits into
bytecodealliance:mainfrom
valobanov:main
Jul 15, 2025
Merged

Fix Instance.GetMemories() ignored memories after the 1st non-memory export#326
jsturtevant merged 2 commits into
bytecodealliance:mainfrom
valobanov:main

Conversation

@valobanov
Copy link
Copy Markdown
Contributor

  • Fix similar Instance.GetFunctions(), GetTables(), GetGlobals() methods

GetMemories() returned empty list for following code but worked fine after swapping 2 exports:
(module (type $t0 (func)) (func $run) (memory $0 1)
(export "run" (func $run))
(export "memory" (memory 0))
)

…export

* Fix similar Instance.GetFunctions(), GetTables(), GetGlobals() methods

GetMemories() returned empty list for following code but worked fine after swapping 2 exports:
    (module (type $t0 (func)) (func $run) (memory $0 1)
      (export "run" (func $run))
      (export "memory" (memory 0))
    )
@martindevans
Copy link
Copy Markdown
Contributor

@jsturtevant I'd recommend merging this before cutting a new release.

@jsturtevant jsturtevant merged commit cb3be0b into bytecodealliance:main Jul 15, 2025
6 checks passed
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.

3 participants