From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id 0504B6EC5F; Thu, 15 Apr 2021 02:04:32 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 0504B6EC5F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1618441472; bh=Hioc1rZfE2Zs70kLr68DBFPqeXPNZMWfMLMgVQo8His=; h=To:References:Date:In-Reply-To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=rCJoqTIfdZuH4/VpwawLpvR0CXApovFMT6jL2VeXxIQ2btWZYyAYdH3hRoD37nwDa FrggMXg3u267Qu68bOT6Zyd3Wt2gy+iDGhnAS3q41k4866awSKqJGbRdmrj5MglKzP CgP30o2MesOQPL15rpEAV8DTnQAjPAbtKbliw7Bc= Received: from smtpng2.m.smailru.net (smtpng2.m.smailru.net [94.100.179.3]) (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 7BA106EC5F for ; Thu, 15 Apr 2021 02:04:29 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 7BA106EC5F Received: by smtpng2.m.smailru.net with esmtpa (envelope-from ) id 1lWoYe-0005Hv-Gc; Thu, 15 Apr 2021 02:04:28 +0300 To: Mergen Imeev References: <20210413165753.GA185709@tarantool.org> Message-ID: <0bcee380-6112-d466-fb1c-b1e8a62205c2@tarantool.org> Date: Thu, 15 Apr 2021 01:04:27 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.9.1 MIME-Version: 1.0 In-Reply-To: <20210413165753.GA185709@tarantool.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD92FFCB8E6708E74809299FB6B3996B874F289A033C44AD400182A05F53808504007C8C3CF4ED068630CBC70048C468965673BEE1FFD623789C8956A58AAB1028A X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7D950999244A4B2E6EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F79006377A06FA5CCF78F9BC8638F802B75D45FF914D58D5BE9E6BC1A93B80C6DEB9DEE97C6FB206A91F05B2E8CEE5DC6EC16F824B9965583A32B2B60E47C10036089472D2E47CDBA5A96583C09775C1D3CA48CFE97D2AE7161E217F117882F4460429724CE54428C33FAD30A8DF7F3B2552694AC26CFBAC0749D213D2E47CDBA5A9658378DA827A17800CE74601F13E4625331C9FA2833FD35BB23DF004C906525384302BEBFE083D3B9BA73A03B725D353964B0B7D0EA88DDEDAC722CA9DD8327EE4930A3850AC1BE2E7358CCB3ED2A1DE2304C4224003CC83647689D4C264860C145E X-B7AD71C0: AC4F5C86D027EB782CDD5689AFBDA7A2AD77751E876CB595E8F7B195E1C97831494DE4B1D18D788F0D9CEC0EA6A0B831 X-C1DE0DAB: 0D63561A33F958A5B9B077963611FEE1EAAB979ADD81605AC786F56EF3442E78D59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA7502E6951B79FF9A3F410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D349A401E2B4D763A4A575FB2A8A59C129672EDD202951EC16C18D6B84AC8E82DFF11FD63C4B0F8D76E1D7E09C32AA3244C00905352D2367272284DE4F667D47016A8CE788DE6831205FACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojrcJA+pXcDulWT5gVkOjwcg== X-Mailru-Sender: 689FA8AB762F73936BC43F508A063822337EDAB5A67AD6D509972A15F342F2C63841015FED1DE5223CC9A89AB576DD93FB559BB5D741EB963CF37A108A312F5C27E8A8C3839CE0E267EA787935ED9F1B X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH v5 18/52] sql: introduce mem_concat() X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Vladislav Shpilevoy via Tarantool-patches Reply-To: Vladislav Shpilevoy Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Thanks for the discussion! >>> diff --git a/src/box/sql/mem.c b/src/box/sql/mem.c >>> index b417c1007..2d76ef88d 100644 >>> --- a/src/box/sql/mem.c >>> +++ b/src/box/sql/mem.c >>> @@ -326,6 +326,70 @@ mem_move(struct Mem *to, struct Mem *from) >>> return 0; >>> } >>> >>> +static bool >>> +is_result_null(const struct Mem *a, const struct Mem *b, struct Mem *result, >>> + enum field_type type) >> >> 1. Functions called 'is_*' never should change anything. >> > Fixed. Renamed to check_result_null(). > >> Another question is why do you even need it? It is used in a single place, >> where it could be just inlined. And is not used in a place, where it could >> be applied. >> > I added it here since it was the first commit, which used it. This functions > will be used in all arithmetic and bitwise operations with two operands. I hope it is not too late to rename it to try_return_null()? Because sorry, but 'check' also has a meaning - it is just like 'is' (does not change anything), but sets a diag. At least this is what I see in the code usually, and try to force in the new patches.