From 4b61495576bc240392d7aaaec38ecac8631e447c Mon Sep 17 00:00:00 2001 From: Alexander Barkov Date: Tue, 16 Aug 2016 10:24:12 +0400 Subject: MDEV-10411 Providing compatibility for basic PL/SQL constructs Part 9: EXCEPTION handlers EXCEPTION is now supported in inner blocks. --- sql/structs.h | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'sql/structs.h') diff --git a/sql/structs.h b/sql/structs.h index 24a96276c4e..f0c3926e424 100644 --- a/sql/structs.h +++ b/sql/structs.h @@ -628,12 +628,20 @@ public: int dyncol_type() const { return m_type; } }; -struct Lex_spblock_st + +struct Lex_spblock_handlers_st +{ +public: + int hndlrs; + void init(int count) { hndlrs= count; } +}; + + +struct Lex_spblock_st: public Lex_spblock_handlers_st { public: int vars; int conds; - int hndlrs; int curs; void init() { @@ -653,6 +661,11 @@ class Lex_spblock: public Lex_spblock_st { public: Lex_spblock() { init(); } + Lex_spblock(const Lex_spblock_handlers_st &other) + { + vars= conds= curs= 0; + hndlrs= other.hndlrs; + } }; #endif /* STRUCTS_INCLUDED */ -- cgit v1.2.1