• Alexander Barkov's avatar
    Optimization for MDEV-10411 Providing compatibility for basic PL/SQL constructs · d2b007d6
    Alexander Barkov authored
    When processing an SP body:
    
    CREATE PROCEDURE p1 (parameters)
    AS [ declarations ]
    BEGIN statements
    [ EXCEPTION exceptions ]
    END;
    
    the parser generates two "jump" instructions:
    - from the end of "declarations" to the beginning of EXCEPTION
    - from the end of EXCEPTION to "statements"
    
    These jumps are useless if EXCEPTION does not exist.
    This patch makes sure that these two "jump" instructions are
    generated only if EXCEPTION really exists.
    d2b007d6
sp_head.cc 114 KB