From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.devel Subject: Re: master 1e3b0f2: Improve doc strings of project.el Date: Sat, 20 Jun 2020 14:35:24 +0300 Message-ID: <90f4c9e8-bf8d-3b27-a8a9-ed44c5d23839@yandex.ru> References: <87bllfqj82.fsf@warpmail.net> <626efe11-0f9c-081b-11dd-0d61cee8168d@yandex.ru> <83h7v7xf7w.fsf@gnu.org> <831rmayj55.fsf@gnu.org> <6dc2c2ac-8e17-f044-dc78-8c109f936ad2@yandex.ru> <83wo42w83e.fsf@gnu.org> <83a70yw1y8.fsf@gnu.org> <87mu4ym6f6.fsf@thornhill.no> <834kr6vymb.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="5707"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 Cc: philip@warpmail.net, emacs-devel@gnu.org To: Eli Zaretskii , Theodor Thornhill Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Jun 20 13:36:17 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jmbnF-0001Mq-JU for ged-emacs-devel@m.gmane-mx.org; Sat, 20 Jun 2020 13:36:17 +0200 Original-Received: from localhost ([::1]:35194 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jmbnE-0002W7-Mk for ged-emacs-devel@m.gmane-mx.org; Sat, 20 Jun 2020 07:36:16 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53594) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jmbmT-0001qW-EO for emacs-devel@gnu.org; Sat, 20 Jun 2020 07:35:29 -0400 Original-Received: from mail-ej1-x635.google.com ([2a00:1450:4864:20::635]:36137) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jmbmS-0002k9-1a; Sat, 20 Jun 2020 07:35:29 -0400 Original-Received: by mail-ej1-x635.google.com with SMTP id dr13so13090669ejc.3; Sat, 20 Jun 2020 04:35:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=BDZ7+1fBWTjzhi07vDbIKllktxgKq7K4iUnXObkgFOk=; b=aaCRB7Y5wJNx0/m0ehTwxYu+arUIi1UDlq/Y6a4UGUsvh/Flmf1iwI9CfDGz0qOg9u pbF1tnRi2xOHmU8u7P7cs80ARQydiQDOg2J4T8YwMERAG679wJNIdldNOwUuU1PTIEts eeAVkXJ31TTvGLloQ9EATjQrvWu+o39obgC8j1Ps9pQ4vTGfMsWQmgf9F7SCBGR2fpux Iyir6lZvsT1JqsfeWEqsCMADM8fm6BbFd1XlFlZCrYLurG05l581g0PiunLFXyV4OsNN sFzRroWyhffOZqhX51EcyPqusChguFMa3ThLqho9gdzti1qB4Y/FBzJc7up9TLcf+wQL XbOw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=BDZ7+1fBWTjzhi07vDbIKllktxgKq7K4iUnXObkgFOk=; b=kNHekrnyeq9OcVUqGiyfqY1K97rGQS1E4nu0XBFIHBxiHFx7A+Bl/c/SlIodTWrx9l Mb3+uBzGPAXv98/KvsULXiCUoiqNmKjpp5xXGwGCf6aGP1kffLr0v1lSAaqtlEXf4/Bb KF19V3ZI+AYw/37qXSmf9B25fwbO7uYYQZ518uuiZWdcOotjc9z/lUfkQIXNlCHoE9rW jxe1/vuuF4q6G+7b5fW7+R/7XI/uW1OXY+5sBtGA5oNTYH6s3xVu8+u7WEt6F6k4w+O3 pq9Px1hlRiPujd0OrXSp0ziPPpt/LHBdFHWFpQAY1oNVp0QfEe2CromoKafQCcRnocm1 5kXQ== X-Gm-Message-State: AOAM531eW/Dof95HBfvSeypGLhPc1cyMSBCFRu4Q/GEimKEfli6MvAfQ TmJnchIQRYlz6to+UpHdNOHjckyC X-Google-Smtp-Source: ABdhPJwMoo5fzMmJVbDFavl+iETUgh3O3ceeLss5h1aLkbX1S5Hke2H9zEX9WTznctBEXodzGSY+IQ== X-Received: by 2002:a17:907:7014:: with SMTP id wr20mr7457250ejb.251.1592652925949; Sat, 20 Jun 2020 04:35:25 -0700 (PDT) Original-Received: from [192.168.0.3] ([66.205.73.129]) by smtp.googlemail.com with ESMTPSA id i9sm7124292ejv.44.2020.06.20.04.35.24 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 20 Jun 2020 04:35:25 -0700 (PDT) In-Reply-To: <834kr6vymb.fsf@gnu.org> Content-Language: en-US Received-SPF: pass client-ip=2a00:1450:4864:20::635; envelope-from=raaahh@gmail.com; helo=mail-ej1-x635.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: 0 X-Spam_score: 0.0 X-Spam_bar: / X-Spam_report: (0.0 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=1, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:252431 Archived-At: On 20.06.2020 13:07, Eli Zaretskii wrote: > In any case, my proposal was not about the API itself, it was more > about the implementation of the API. For example, we could have an > implementation of the generic project-files API that consulted some > list instead of asking the VCS or the filesystem to provide the files. You can of course do this already, in 10 lines or so. But imagine you did add such a backend where project-files returns an arbitrary list of files. And you use it. How would project-switch-to-buffer consult it? Will it have to call project-files now, as opposed to just using project-root as the basis for comparison? And then compare buffer-file-name of all file-visiting buffers against that list? That would work for smaller projects, but in large ones project-files is not instantaneous, so they will be penalized in performance by such an approach. And project-switch-to-buffer should work with all kinds of projects. That also wouldn't solve the problem of non-file-visiting buffers like Grep from your example.