hi,

It's not the same between these 2 :

WHEN 2
 CONTINUE
WHEN 3
 ...
in this case CONTINUE is a BRANCH to END-EVALUATE

and 
WHEN 2
WHEN 3
in this case WHEN 2 execute the same instruction as WHEN 3

HTH
René     Le lundi 25 septembre 2023 à 23:55:30 UTC+2, Binyamin Dissen 
<[email protected]> a écrit :  
 
 On Mon, 25 Sep 2023 16:32:57 -0400 Dave Clark <[email protected]>
wrote:

:>        In COBOL, an EVALUATE-WHEN-END-EVALUATE construct can use the 
:>CONTINUE verb as a placeholder where you would normally need an imperative 
:>statement.  Well, in ASSEMBLER I have a SELECT-WHEN-ENDSL construct in 
:>which I now need the same kind of placeholder instruction.  In storage I 
:>have used CNOP for alignment purposes but I don't think that is what I 
:>want in this case.  I know there are a number of instructions (compare, 
:>branch, etc) that CAN be used as such a placeholder but the manual says 
:>these are not the best way to do that kind of thing.  But it doesn't say 
:>what IS the best way to do this and I don't see a NOP or NOOP -- as I 
:>would expect.  What am I missing?!?

Just put another WHEN right after it.


      SELECT
          WHEN  1
                something
          WHEN  2
          WHEN  3
                something
      ENDSEL ,

No need for a placeholder instruction.

--
Binyamin Dissen <[email protected]>
http://www.dissensoftware.com

Director, Dissen Software, Bar & Grill - Israel
  

Reply via email to