> Could someone please clarify whether a return statement is allowed inside
> the blocks of if if/else and while statements in UDOs. [...]
Good catch, it does seem like Annex 5.C.3's grammar is inconsistent
with 5.8.7.6.1 in this regard -- the grammar implements:
<opcode statement> -> <statement>
< statement> -> return( <expr list> );
instead of
<opcode statement> -> <statement>
<opcode statement> -> return( <expr list> );
and sfront and (I believe) saolc both follow Annex 5.C.3 and permit
return()'s inside of blocks (note that the Annex 5.C.3 grammar actually
allows return() statements in instrs, which need to be syntax-checked
away post-parse).
--jl
-------------------------------------------------------------------------
John Lazzaro -- Research Specialist -- CS Division -- EECS -- UC Berkeley
lazzaro [at] cs [dot] berkeley [dot] edu www.cs.berkeley.edu/~lazzaro
-------------------------------------------------------------------------
This archive was generated by hypermail 2b29 : Mon Jan 28 2002 - 12:03:58 EST