@@ -55,7 +55,7 @@ class Dispatcher;
5555class YObject
5656{
5757public:
58- YObject ()
58+ YObject () noexcept
5959 : handle(0 )
6060 {
6161 }
@@ -131,8 +131,8 @@ class YHelper : public Firebird::RefCntIface<Intf>, public YObject
131131 typedef typename Intf::Declaration NextInterface;
132132 typedef YAttachment YRef;
133133
134- static const unsigned DF_RELEASE = 0x1 ;
135- static const unsigned DF_KEEP_NEXT = 0x2 ;
134+ static constexpr unsigned DF_RELEASE = 0x1 ;
135+ static constexpr unsigned DF_KEEP_NEXT = 0x2 ;
136136
137137 explicit YHelper (NextInterface* aNext, const char * m = NULL )
138138 :
@@ -178,12 +178,12 @@ template <class YT>
178178class AtomicYPtr
179179{
180180public:
181- AtomicYPtr (YT* v)
181+ AtomicYPtr (YT* v) noexcept
182182 {
183183 atmPtr.store (v, std::memory_order_relaxed);
184184 }
185185
186- YT* get ()
186+ YT* get () noexcept
187187 {
188188 return atmPtr.load (std::memory_order_relaxed);
189189 }
@@ -207,7 +207,7 @@ class YEvents final :
207207 public YHelper<YEvents, Firebird::IEventsImpl<YEvents, Firebird::CheckStatusWrapper> >
208208{
209209public:
210- static const ISC_STATUS ERROR_CODE = isc_bad_events_handle;
210+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_events_handle;
211211
212212 YEvents (YAttachment* aAttachment, Firebird::IEvents* aNext, Firebird::IEventCallback* aCallback);
213213
@@ -230,7 +230,7 @@ class YRequest final :
230230 public YHelper<YRequest, Firebird::IRequestImpl<YRequest, Firebird::CheckStatusWrapper> >
231231{
232232public:
233- static const ISC_STATUS ERROR_CODE = isc_bad_req_handle;
233+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_req_handle;
234234
235235 YRequest (YAttachment* aAttachment, Firebird::IRequest* aNext);
236236
@@ -260,7 +260,7 @@ class YTransaction final :
260260 public YHelper<YTransaction, Firebird::ITransactionImpl<YTransaction, Firebird::CheckStatusWrapper> >
261261{
262262public:
263- static const ISC_STATUS ERROR_CODE = isc_bad_trans_handle;
263+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_trans_handle;
264264
265265 YTransaction (YAttachment* aAttachment, Firebird::ITransaction* aNext);
266266
@@ -316,7 +316,7 @@ class YBlob final :
316316 public YHelper<YBlob, Firebird::IBlobImpl<YBlob, Firebird::CheckStatusWrapper> >
317317{
318318public:
319- static const ISC_STATUS ERROR_CODE = isc_bad_segstr_handle;
319+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_segstr_handle;
320320
321321 YBlob (YAttachment* aAttachment, YTransaction* aTransaction, Firebird::IBlob* aNext);
322322
@@ -344,7 +344,7 @@ class YResultSet final :
344344 public YHelper<YResultSet, Firebird::IResultSetImpl<YResultSet, Firebird::CheckStatusWrapper> >
345345{
346346public:
347- static const ISC_STATUS ERROR_CODE = isc_bad_result_set;
347+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_result_set;
348348
349349 YResultSet (YAttachment* anAttachment, YTransaction* aTransaction, Firebird::IResultSet* aNext);
350350 YResultSet (YAttachment* anAttachment, YTransaction* aTransaction, YStatement* aStatement,
@@ -379,7 +379,7 @@ class YBatch final :
379379 public YHelper<YBatch, Firebird::IBatchImpl<YBatch, Firebird::CheckStatusWrapper> >
380380{
381381public:
382- static const ISC_STATUS ERROR_CODE = isc_bad_result_set; // isc_bad_batch
382+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_result_set; // isc_bad_batch
383383
384384 YBatch (YAttachment* anAttachment, Firebird::IBatch* aNext);
385385
@@ -411,7 +411,7 @@ class YReplicator final :
411411 public YHelper<YReplicator, Firebird::IReplicatorImpl<YReplicator, Firebird::CheckStatusWrapper> >
412412{
413413public:
414- static const ISC_STATUS ERROR_CODE = isc_bad_repl_handle;
414+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_repl_handle;
415415
416416 YReplicator (YAttachment* anAttachment, Firebird::IReplicator* aNext);
417417
@@ -430,7 +430,7 @@ class YReplicator final :
430430class YMetadata
431431{
432432public:
433- explicit YMetadata (bool in)
433+ explicit YMetadata (bool in) noexcept
434434 : flag(false ), input(in)
435435 { }
436436
@@ -446,7 +446,7 @@ class YStatement final :
446446 public YHelper<YStatement, Firebird::IStatementImpl<YStatement, Firebird::CheckStatusWrapper> >
447447{
448448public:
449- static const ISC_STATUS ERROR_CODE = isc_bad_stmt_handle;
449+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_stmt_handle;
450450
451451 YStatement (YAttachment* aAttachment, Firebird::IStatement* aNext);
452452
@@ -494,7 +494,7 @@ class YStatement final :
494494class EnterCount
495495{
496496public:
497- EnterCount ()
497+ EnterCount () noexcept
498498 : enterCount(0 )
499499 {}
500500
@@ -512,15 +512,15 @@ class YAttachment final :
512512 public EnterCount
513513{
514514public:
515- static const ISC_STATUS ERROR_CODE = isc_bad_db_handle;
515+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_db_handle;
516516
517517 YAttachment (Firebird::IProvider* aProvider, Firebird::IAttachment* aNext,
518518 const Firebird::PathName& aDbPath);
519519 ~YAttachment ();
520520
521521 void destroy (unsigned dstrFlags) override ;
522522 void shutdown ();
523- isc_db_handle& getHandle ();
523+ isc_db_handle& getHandle () noexcept ;
524524 void getOdsVersion (USHORT* majorVersion, USHORT* minorVersion);
525525
526526 // IAttachment implementation
@@ -610,14 +610,14 @@ class YService final :
610610 public EnterCount
611611{
612612public:
613- static const ISC_STATUS ERROR_CODE = isc_bad_svc_handle;
613+ static constexpr ISC_STATUS ERROR_CODE = isc_bad_svc_handle;
614614
615615 YService (Firebird::IProvider* aProvider, Firebird::IService* aNext, bool utf8, Dispatcher* yProvider);
616616 ~YService ();
617617
618618 void shutdown ();
619619 void destroy (unsigned dstrFlags) override ;
620- isc_svc_handle& getHandle ();
620+ isc_svc_handle& getHandle () noexcept ;
621621
622622 // IService implementation
623623 void detach (Firebird::CheckStatusWrapper* status) override ;
@@ -648,7 +648,7 @@ class Dispatcher final :
648648 public Firebird::StdPlugin<Firebird::IProviderImpl<Dispatcher, Firebird::CheckStatusWrapper> >
649649{
650650public:
651- Dispatcher ()
651+ Dispatcher () noexcept
652652 : cryptCallback(NULL )
653653 { }
654654
@@ -663,7 +663,7 @@ class Dispatcher final :
663663 void setDbCryptCallback (Firebird::CheckStatusWrapper* status,
664664 Firebird::ICryptKeyCallback* cryptCallback) override ;
665665
666- void destroy (unsigned )
666+ void destroy (unsigned ) noexcept
667667 { }
668668
669669public:
0 commit comments