Skip to content

wasm-interp: Fix off-by-one in DoThrow#2486

Merged
sbc100 merged 2 commits into
WebAssembly:mainfrom
SoniEx2:interp-try-off-by-one
Oct 8, 2024
Merged

wasm-interp: Fix off-by-one in DoThrow#2486
sbc100 merged 2 commits into
WebAssembly:mainfrom
SoniEx2:interp-try-off-by-one

Conversation

@SoniEx2

@SoniEx2 SoniEx2 commented Oct 8, 2024

Copy link
Copy Markdown
Collaborator

No description provided.

@sbc100 sbc100 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

No test output changed as the result of this? Would writing a test for this be tricky?

I don't really know this code myself but the change looks reasonable.

@SoniEx2

SoniEx2 commented Oct 8, 2024

Copy link
Copy Markdown
Collaborator Author

yeah upstream doesn't have tests for this.

uh hmm... we're not sure how to trigger this, maybe something like

throw
try
catch
end

?

@SoniEx2

SoniEx2 commented Oct 8, 2024

Copy link
Copy Markdown
Collaborator Author

(yep:

  +out/test/regress/interp-throw-before-try.txt:15: expected an exception to be thrown
  +1/2 tests passed.

)

@SoniEx2

SoniEx2 commented Oct 8, 2024

Copy link
Copy Markdown
Collaborator Author

@sbc100

@sbc100 sbc100 merged commit 7fdccf7 into WebAssembly:main Oct 8, 2024
@SoniEx2 SoniEx2 deleted the interp-try-off-by-one branch October 8, 2024 19:02
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