3030#include " ../common/sdl_proto.h"
3131#include " ../common/StatusArg.h"
3232
33- const int COMPILE_SIZE = 256 ;
33+ constexpr int COMPILE_SIZE = 256 ;
3434
3535using namespace Jrd ;
3636using namespace Firebird ;
@@ -66,7 +66,7 @@ static ISC_STATUS error(CheckStatusWrapper* status_vector, const Arg::StatusVect
6666static bool execute (sdl_arg*);
6767static const UCHAR* get_range (const UCHAR*, array_range*, SLONG*, SLONG*);
6868
69- inline SSHORT get_word (const UCHAR*& ptr)
69+ inline SSHORT get_word (const UCHAR*& ptr) noexcept
7070{
7171/* *************************************
7272 *
@@ -89,18 +89,18 @@ static const UCHAR* sdl_desc(const UCHAR*, DSC*);
8989static IPTR* stuff (IPTR, sdl_arg*);
9090
9191
92- const int op_literal = 1 ;
93- const int op_variable = 2 ;
94- const int op_add = 3 ;
95- const int op_subtract = 4 ;
96- const int op_multiply = 5 ;
97- const int op_divide = 6 ;
98- const int op_iterate = 7 ;
99- const int op_goto = 8 ;
100- const int op_element = 9 ;
101- const int op_loop = 10 ;
102- const int op_exit = 11 ;
103- const int op_scalar = 12 ;
92+ constexpr int op_literal = 1 ;
93+ constexpr int op_variable = 2 ;
94+ constexpr int op_add = 3 ;
95+ constexpr int op_subtract = 4 ;
96+ constexpr int op_multiply = 5 ;
97+ constexpr int op_divide = 6 ;
98+ constexpr int op_iterate = 7 ;
99+ constexpr int op_goto = 8 ;
100+ constexpr int op_element = 9 ;
101+ constexpr int op_loop = 10 ;
102+ constexpr int op_exit = 11 ;
103+ constexpr int op_scalar = 12 ;
104104
105105/*
106106 The structure for a loop is:
@@ -157,7 +157,7 @@ SLONG SDL_compute_subscript(CheckStatusWrapper* status_vector,
157157
158158
159159ISC_STATUS SDL_info (CheckStatusWrapper* status_vector,
160- const UCHAR* sdl, sdl_info* info, SLONG* vector)
160+ const UCHAR* sdl, sdl_info* info, const SLONG* vector)
161161{
162162/* *************************************
163163 *
@@ -407,12 +407,15 @@ static const UCHAR* compile(const UCHAR* sdl, sdl_arg* arg)
407407
408408 case isc_sdl_add:
409409 sdl_operator = op_add;
410+ [[fallthrough]];
410411 case isc_sdl_subtract:
411412 if (!sdl_operator)
412413 sdl_operator = op_subtract;
414+ [[fallthrough]];
413415 case isc_sdl_multiply:
414416 if (!sdl_operator)
415417 sdl_operator = op_multiply;
418+ [[fallthrough]];
416419 case isc_sdl_divide:
417420 if (!sdl_operator)
418421 sdl_operator = op_divide;
0 commit comments