Yep: the REX[X] VM implementation was/is a true ‘interpreter’ .. it executes the program ‘live’ from the source.
It parses the tokens on reading the file but other than that it carries out no analysis, because that would have made the initial startup time on those machines absurdly slow, especially compared to EXEC2. So, an unwise SIGNAL to a label would only be detected when reaching an invalid state. But a SIGNAL to a label within the same block would not result in a state problem, and no error. In short: if ‘following the flow of control by hand’ made sense, then the interpreter gave the same result. Perhaps not a bad way for things to work. Static pre-analysis can save time, of course, but can also give ‘unexpected’ results. Mike From: Gilbert Barmwater via Oorexx-devel <[email protected]> Sent: 26 May 2026 17:01 To: [email protected] Cc: Gilbert Barmwater <[email protected]> Subject: Re: [Oorexx-devel] Labels Yes, I hadn't taken the time to review ANSI but it spells out the "right" behavior IMO. Gil On 5/26/2026 11:49 AM, Josep Maria Blasco wrote: Missatge de Gilbert Barmwater via Oorexx-devel <[email protected] <mailto:[email protected]> > del dia dt., 26 de maig 2026 a les 17:37: Sorry for the late response. I agree this should be changed BUT we need to make sure that we "catch" all the ways that "trace-only" labels might be used incorrectly. I think that list is a) target of SIGNAL, b) target of CALL, and c) target of a function call. I'd be interested in what VM/CMS Rexx does in those scenarios. Well, it does interesting things. For example, /* REXX */ TRACE L A: DO SIGNAL S S: SIGNAL OUT E: END OUT: NOP prints Ready; T=0.01/0.01 16:47:02 test 3 *-* A: 5 *-* S: 7 *-* OUT: Ready; T=0.01/0.01 16:47:04 I'm not proposing to emulate this behaviour. ANSI should be enough: 6.4.2 Trace-only labels Instances of LABEL which occur within a grouping_instruction and are not in a ncl at the end of thatgrouping_instruction are instances of trace-only labels Josep Maria Gil On 5/26/2026 9:55 AM, Mike Cowlishaw wrote: > +1 (labels are just names). > > Mike > > -----Original Message----- > From: J Leslie Turriff via Oorexx-devel > <[email protected] > <mailto:[email protected]> > > Sent: 25 May 2026 00:19 > To: Open Object Rexx Developer Mailing List > <[email protected] > <mailto:[email protected]> > > Cc: J Leslie Turriff <[email protected] <mailto:[email protected]> > > Subject: Re: [Oorexx-devel] Labels > > I agree; because labels can be used as a debugging aid as well as > targets of branches, it would make sense to allow labels anywhere, but > prohibit branching to them where such actions are not appropriate. > > Lelsie > > > > > _______________________________________________ > Oorexx-devel mailing list > [email protected] > <mailto:[email protected]> > https://lists.sourceforge.net/lists/listinfo/oorexx-devel -- Gil Barmwater _______________________________________________ Oorexx-devel mailing list [email protected] <mailto:[email protected]> https://lists.sourceforge.net/lists/listinfo/oorexx-devel _______________________________________________ Oorexx-devel mailing list [email protected] <mailto:[email protected]> https://lists.sourceforge.net/lists/listinfo/oorexx-devel -- Gil Barmwater
_______________________________________________ Oorexx-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/oorexx-devel
