WORDS-OF TRY [BREAK] crashes #1535
Labels
CC.resolved
Issue with CureCode status built, tested or complete
Status.important
Test.written
Type.bug
Submitted by: meijeru
This is one of the cases where TRY yields a "special" error value (code < 100). WORDS-OF TRY [1 / 0] works normally.
Imported from: CureCode [ Version: alpha 97 Type: Bug Platform: All Category: Error Handling Reproduce: Always Fixed-in:alpha 98 ]
Imported from: metaeducation#1535
Comments:
Submitted by: BrianH
This is a side effect of bug #1509. The unwind values don't have words, so WORDS-OF shouldn't work on them. However, the unwind values should never be passed as an argument to the function in the first place; they should propagate instead. So there is no problem with the behavior of the function itself: The error is in the call to the function, as done by DO.
Submitted by: Ladislav
"However, the unwind values should never be passed as an argument to the function in the first place;" - certainly, triggered unwinds shall not be in the "Rebol value space", not being "normally manipulable" by any Rebol function, and existing only as "ghosts". If wished, untriggered unwinds can be defined as "regular Rebol values", but it probably isn't necessary.
Submitted by: BrianH
There is no such thing as an untriggered unwind value as far as REBOL code is concerned. You can't make an unwind value without triggering it. And any code which is able to treat an unwind value as if it were an untriggered error! value is a major security hole, which should be reported here. See #1004, #1509, #1515 and #1519 for other examples of that security hole.
Submitted by: Carl
In A98 it no longer crashes, but returns a new error indicating that such usage is not valid.
Submitted by: Ladislav
While not causing a crash now, the behaviour is still incorrect. See #1509
Submitted by: BrianH
#1509 is now fixed, so we can consider this one fixed as well.
The text was updated successfully, but these errors were encountered: