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 A54D07030E; Mon, 25 Jan 2021 01:33:01 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org A54D07030E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1611527581; bh=pQ4i3sxp6izoYlw77L1wzlwIaurQTq326aCbt9Ej0UI=; h=Date:To:Cc:References:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=ZUgbwixmstrjnn32YumJGzndG7plAGN1/hAg6UQfXjNEPr8phKEzCPoFPTMFAhNEd 9UmD6YMkZxzqu6V7w8xuotDKvSbwuKaG5YV9VUVBUbWT+hY90jJDWuWriOkT2AuMaG 6DKFN+z2SiGE6/M2+blhwBztVEp5Vt1WC2om7+lg= Received: from mail-lf1-f53.google.com (mail-lf1-f53.google.com [209.85.167.53]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 9D9347030E for ; Mon, 25 Jan 2021 01:33:00 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 9D9347030E Received: by mail-lf1-f53.google.com with SMTP id o10so15038017lfl.13 for ; Sun, 24 Jan 2021 14:33:00 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=NPctJlkXq7uCuaGvSrR0fXgfhJE8IGzqZnCwKC9+JNk=; b=GaZVpZXUpVJlmIDJkdp/TPN3fwKICoGx/UbK8e7hLb7r4A5sFS9F9clwKjdRhZoKa5 +yLYqVl3iXUjH3mwrJy4+HBMM3o98SYghxrwdLRGnGMTvYMjlbJK2NJNIjYdX8PiTcsy grkIrekeW0l9Ptorx8Ssn6yANo3oGPRYXJjduNEfT7wvk/pGWCWxU1eHmWYYhmd/F4DZ CiGnItxn3e4f1FVv9z9GSEcXR3t673mY4d2jDBuAgNb0MitjQyzItu8p7c8+tEj0iAi6 EHbj3qDw5Q/M1DyHja4zNy/CeuqGoqH+oAcWoP07AE+v1PF0zQq9tkiy0qhze6JrYd4z K4rw== X-Gm-Message-State: AOAM532J0J8hWSL02nW6NxSfobbehBQOTLTCeQpcobsAogkCJjzCT8pL zHNiBrUwyWa/SX8y5CU+PTzulpYihfs= X-Google-Smtp-Source: ABdhPJz7ZQ/sgLwEzt3sZhB9Dy8ntHcgnfMkgIcEam5cYMcnaPPILNNoT1riHoKb45dni1M/bk9PGA== X-Received: by 2002:a19:c356:: with SMTP id t83mr503080lff.484.1611527579497; Sun, 24 Jan 2021 14:32:59 -0800 (PST) Received: from grain.localdomain ([5.18.91.94]) by smtp.gmail.com with ESMTPSA id c127sm1584116lfd.292.2021.01.24.14.32.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 24 Jan 2021 14:32:57 -0800 (PST) Received: by grain.localdomain (Postfix, from userid 1000) id D2D55560099; Mon, 25 Jan 2021 01:32:56 +0300 (MSK) Date: Mon, 25 Jan 2021 01:32:56 +0300 To: Vladislav Shpilevoy Cc: tml Message-ID: <20210124223256.GD2174@grain> References: <20210118203556.281700-1-gorcunov@gmail.com> <20210118203556.281700-4-gorcunov@gmail.com> <03fe6138-05d8-a88d-eae5-05d060b54f7a@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <03fe6138-05d8-a88d-eae5-05d060b54f7a@tarantool.org> User-Agent: Mutt/1.14.6 (2020-07-11) Subject: Re: [Tarantool-patches] [PATCH v12 3/8] module_cache: improve naming 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: Cyrill Gorcunov via Tarantool-patches Reply-To: Cyrill Gorcunov Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" On Sun, Jan 24, 2021 at 05:27:12PM +0100, Vladislav Shpilevoy wrote: > Thanks for the patch! > > Very dubious commit. To me the old and new names look the same. > 'func_name' was even better than 'func_name_desc'. At least > because it was shorter, and 'desc' does not add any more meaning. > > On 18.01.2021 21:35, Cyrill Gorcunov via Tarantool-patches wrote: > > - rename func_name to func_name_desc because > > it is not just a name but rather a name descriptor > > which includes symbol address > > I don't see any address in it. Only name tokens. struct func_name_desc { /** * Null-terminated symbol name, e.g. * "func" for "mod.submod.func". */ ---> const char *sym; /** * Package name, e.g. "mod.submod" for * "mod.submod.func". */ const char *package; /** * A pointer to the last character in ->package + 1. */ const char *package_end; }; I marked the address. The structure is not a function name but consists of two parts - package path and function name itself and maybe something new will be added in future. So func_name is suitable for plain names but not for strings where some part of it has a special meaning with hidden extension inside, hereby a descriptor. And don't forget about grepability, without this name change grep returns a number of irrelevant results.