From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp61.i.mail.ru (smtp61.i.mail.ru [217.69.128.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id E0055445323 for ; Sat, 11 Jul 2020 22:53:27 +0300 (MSK) References: <1594199230-26036-1-git-send-email-alyapunov@tarantool.org> <1594199230-26036-2-git-send-email-alyapunov@tarantool.org> From: Vladislav Shpilevoy Message-ID: <4107c5fb-11af-16df-26e2-2c134dc0a46b@tarantool.org> Date: Sat, 11 Jul 2020 21:53:26 +0200 MIME-Version: 1.0 In-Reply-To: <1594199230-26036-2-git-send-email-alyapunov@tarantool.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [Tarantool-patches] [PATCH 1/2] alter: use good c++ style List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Aleksandr Lyapunov , tarantool-patches@dev.tarantool.org Thanks for the patch! See 3 comments below. On 08/07/2020 11:07, Aleksandr Lyapunov wrote: > We should use noecept where it's appropriate. 1. noecept -> noexcept. 2. I am getting build errors: /Users/gerold/Work/Repositories/tarantool/src/box/alter.cc:1635:16: error: function previously declared with an implicit exception specification redeclared with an explicit exception specification [-Werror,-Wimplicit-exception-spec-mismatch] TruncateIndex::~TruncateIndex() noexcept ^ /Users/gerold/Work/Repositories/tarantool/src/box/alter.cc:1597:2: note: previous declaration is here ~TruncateIndex() override; ^ /Users/gerold/Work/Repositories/tarantool/src/box/alter.cc:1722:23: error: function previously declared with an implicit exception specification redeclared with an explicit exception specification [-Werror,-Wimplicit-exception-spec-mismatch] RebuildCkConstraints::~RebuildCkConstraints() noexcept ^ /Users/gerold/Work/Repositories/tarantool/src/box/alter.cc:1682:2: note: previous declaration is here ~RebuildCkConstraints() override; ^ 2 errors generated. > diff --git a/src/box/alter.cc b/src/box/alter.cc > index bb42548..1a7949e 100644 > --- a/src/box/alter.cc > +++ b/src/box/alter.cc > @@ -1652,14 +1649,14 @@ class UpdateSchemaVersion: public AlterSpaceOp > public: > UpdateSchemaVersion(struct alter_space * alter) > :AlterSpaceOp(alter) {} > - virtual void alter(struct alter_space *alter); > + void alter(struct alter_space *alter) noexcept override; > }; > > void > -UpdateSchemaVersion::alter(struct alter_space *alter) > +UpdateSchemaVersion::alter(struct alter_space *alter) noexcept > { > - (void)alter; > - ++schema_version; > + (void) alter; > + ++schema_version; 3. This change seems not to be related.