Given the following code:
\nBLOCK_A:\n BEGIN;\n some code\n BLOCK_B:\n BEGIN;\n some code within block b\n END; /* unnamed end block - end the last block defined, ie: B\n BLOCK_C:\n BEGIN;\n some code within block c\n END; /* unnamed end block - end the last block defined, ie: C\n Some more code\n END BLOCK_A; /* Named end block */\n
See how the ends balance the begins?
Now look at this:
\n\nBLOCK_A:\n BEGIN;\n some code\n BLOCK_B:\n BEGIN;\n some code within block b\n\n BLOCK_C:\n BEGIN;\n some code within block c\n Some more code\n END BLOCK_A; /* Named end block */ \n
When an END has a name, the compiler KNOWS which block
you are ending. So it doesn't bother trying to balance
opening and closing blocks. This code is perfectly
legal.
The BLOCKS can be part of inner procedures, flow control, part of
"IF"s, etc. I'm leaving that out of the example to show the
minimum amount of code.
Feels dangerous to me.