From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Douglas Lewan Newsgroups: gmane.emacs.help Subject: Return values of (find-file-noselect), etc. Date: Sun, 6 Jan 2019 14:06:21 -0500 Message-ID: <71340fe0-7373-f407-3bc7-7a2dcaf6b3b3@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1546801502 21528 195.159.176.226 (6 Jan 2019 19:05:02 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 6 Jan 2019 19:05:02 +0000 (UTC) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Icedove/52.9.1 To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Jan 06 20:04:58 2019 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from listsout.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ggDjF-0005S8-Fd for geh-help-gnu-emacs@m.gmane.org; Sun, 06 Jan 2019 20:04:57 +0100 Original-Received: from localhost ([127.0.0.1]:39679 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ggDlL-0007b6-TR for geh-help-gnu-emacs@m.gmane.org; Sun, 06 Jan 2019 14:07:07 -0500 Original-Received: from eggsout.gnu.org ([209.51.188.92]:41993 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ggDkt-0007az-1X for help-gnu-emacs@gnu.org; Sun, 06 Jan 2019 14:06:39 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ggDko-0004pK-Ci for help-gnu-emacs@gnu.org; Sun, 06 Jan 2019 14:06:38 -0500 Original-Received: from mail-qt1-x82e.google.com ([2607:f8b0:4864:20::82e]:45905) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ggDko-0004ot-6c for help-gnu-emacs@gnu.org; Sun, 06 Jan 2019 14:06:34 -0500 Original-Received: by mail-qt1-x82e.google.com with SMTP id e5so45538865qtr.12 for ; Sun, 06 Jan 2019 11:06:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=to:from:subject:message-id:date:user-agent:mime-version :content-transfer-encoding:content-language; bh=Z2nvvHQm7zNqYJ1a+eDSvNi5SudohZ+xYWtziUHaLmA=; b=EimIsuF3zO/l844y37Fc2eG9CbEjJh5xaJ3NNxtXzQM/f117Zc6bqgQjKSP1AFTJQn MopxI/z5gbZcBQgzNsiHuiHVQw2LtU7Ei+yC6b91jPdKBpsSBkl3wlvBuL9Ma+Osmry5 X5LxupRJ3ceoECpLZljjjBZ/mmTcdOdFcZGgBissydj7Lfbb3Z/lLtfvWUBoyQrc35kY Tg+TcI3bAKRG6YWOMUmbBdtUyD/NIFAZ1qRhX4PiFnDDJcHMfW4emkIUJ1zzPvXK7xsC CorgEoV75K2jfDNq58lHIH79HWPjvavQDvZ0xPM/cm5U3G7dAu9H98zgWgpkF1lem3WU IxzA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-transfer-encoding:content-language; bh=Z2nvvHQm7zNqYJ1a+eDSvNi5SudohZ+xYWtziUHaLmA=; b=SqOJEmMmjNWz5sH7SlASVoTiN2Q0q2aU0VRvRkcF+NBY6j7ysBdhFSThVO5c7vUC6G SzEgk3TvAUHQPP4RTw2tglcj+6kwhZLjXhKXUkpbmyyiw90q5GEgA6OKVcTFz5hfUByK q/k6XMGQaxspdrJFrLpquWu0xFk3fI9mVU9Kt5TH0oyv77ykXSm8M9xGqbPR6zfU45or Y8AiK8XnXX+pxVq90prd6MSLaT81Uby0nNWBQ85/7lvN/FloTBFLBM+vaTrCceppf+GF xyzr0+/RQWQ0Vcn8aH1ytYb50zMV+2ERi54eDFZvAjSwaSRmO7WRDhZGkRgfgzWxZs3B grhA== X-Gm-Message-State: AA+aEWYfJQNOvr8wd0TOPH/vEdnywGAxQH6WGTK6vxs1jDXiS9IiC3fb FEHycIpwxXur/X4xmNqZBmaNTAQ= X-Google-Smtp-Source: ALg8bN6HepxPR+J/yYvgYP0cZYv8b+oHVyPb/cp0SMNFwH9rEZTLnpD4yacio/lHznPtyMY2q1no8g== X-Received: by 2002:ac8:c7:: with SMTP id d7mr55827495qtg.326.1546801593170; Sun, 06 Jan 2019 11:06:33 -0800 (PST) Original-Received: from [0.0.0.0] (tor.keff.org. [194.71.109.44]) by smtp.gmail.com with ESMTPSA id z207sm27534552qka.57.2019.01.06.11.06.31 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 06 Jan 2019 11:06:32 -0800 (PST) Content-Language: en-GB X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::82e X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:119083 Archived-At: I'm writing cpio-mode for emacs whose definition calls (switch-to-buffer) to present an affiliated buffer that contains a dired-like interface. If I have my emacs environment set up to call (cpio-mode) when it detects that a file is a cpio archive, then, e.g. (find-file-noselect "cpio-archive"), returns the dired-style buffer, not the buffer of the found file. So, any processing based on the newly found file is done with the dired-style buffer instead of the buffer with the newly found file. Is that the expected behavior? The docstring(s) are vague about the return value for finding one file. It's explicit about finding multiple files using wildcards. The info documentation, however, is explicit about the return value for finding one file. On the other hand, these functions boil down to (find-file-noselect-1), which returns the value from (current-buffer). That is, it may be returning a value that wasn't made explicit. I'm really just curious. Thanks. -- ,Doug Douglas Lewan +1 (908) 720-7908 Give me "assloads of config" over "some other person thought they could decide what I like" any day. - Szmo, on reddit, 2017 Sep 05