Fredrik,
Yes. This is a question that is actually in the backlog for my OpenVMS Consultant column on OpenVMS.org (see
http://www.openvms.org ).
The way that a case/switch (aka FORTRAN computed GOTO) is handled is via use of symbol substitution, to wit:
$ X = 15
$ ...
$ IF (X .LT. 0) .OR. (X. GT. 20)
$ THEN
$ .... (Error Processing) ...
$ ENDIF
$!
$ GOTO TARGET_'X'
$!
$ TARGET_0:
$ ...
$ GOTO TARGET_COMMON:
$!
$ TARGET_1:
$ ...
$ TARGET_20:
$ ...
$ TARGET_COMMON:
The usual tricks that can be done with this class of construct (e.g., coalescing different cases) are straightforward.
I hope that the above is helpful.
- Bob Gezelter,
http://www.rlgsc.com