SUBROUTINE X(A,B,C) CHARACTER*(*) A, B, C LOGICAL LFUNC IF (LFUNC (A//B)) THEN CALL SUBR1 ELSE IF (LFUNC (A//C)) THEN CALL SUBR2 ELSE CALL SUBR3 END
The arguments to the two calls to
require dynamic allocation (at run time),
but are not required during execution of the
So, the scopes of those temporaries must be within blocks inside
the block corresponding to the Fortran
This cannot be represented "naturally"
in vanilla C, nor in GBEL.
provided by both languages must,
for a given
share the same C/GBE block.
Therefore, any temporaries needed during evaluation of
must either have been predeclared
at the top of the corresponding
or declared within a new block for that
ELSE IF--a block that,
since it cannot contain the
else if itself
(due to the above requirement),
actually implements the rest of the
ELSE IF and
within an inner block.
The FFE takes the latter approach.