-
Notifications
You must be signed in to change notification settings - Fork 36
Conversation
- Removes the sentence that catchless `try` is the same as a regular `block`, because it can be targetted by `delegate`. - Improves a few sentences - Adds examples for catchless try Closes WebAssembly#164.
@@ -258,6 +258,18 @@ end | |||
The `rethrow` here references `try $l2`, but the `rethrow` is not within its | |||
`catch` block. | |||
|
|||
Also, targetting a label of `catch`-less `try` or `try`-`delegate` is also a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I still don't see the relevance of the "catch-less" here, I think it's misleading: the example is a validation failure regardless of whether you add a catch clause or not. Both examples are invalid simply because rethrow does not reference a catch-block, no other reason.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the whole added paragraph here about rethrow
is not really meaningful and also misleading as you suggested. This PR's goal was to clarify about catchless try and its relationship w/ delegate
, so I'll delete this whole paragraph and example.
@@ -258,6 +258,18 @@ end | |||
The `rethrow` here references `try $l2`, but the `rethrow` is not within its | |||
`catch` block. | |||
|
|||
Also, targetting a label of `catch`-less `try` or `try`-`delegate` is also a | |||
validation failure, because `rethrow` is not within a `catch` or `catch_all`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This part is confusing as well: even if there was a surrounding catch somewhere it would still be invalid. Whether a catch exists is irrelevant, it only matters whether the rethrow references a catch.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Deleted.
Co-authored-by: Andreas Rossberg <[email protected]>
Co-authored-by: Andreas Rossberg <[email protected]>
try
is the same as a regularblock
, because it can be targetted bydelegate
.Closes #164.