[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Return values of (find-file-noselect), etc.

From: Douglas Lewan
Subject: Re: Return values of (find-file-noselect), etc.
Date: Tue, 8 Jan 2019 14:12:27 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Icedove/52.9.1

Ok. I'll look into it. Don't expect this immediately though. (One
problem I see right away is that associating an entry contents buffer
correctly might require a different mechanism.

On 01/08/2019 01:07 PM, Stefan Monnier wrote:
>>>> Either way, that's not what I'm seeing. Should this be recorded as a bug?
>>> I think it's a bug for a major mode function to change the current
>>> buffer, so what you're seeing is likely the result of find-file-noselect
>>> not protecting itself against such misbehaving major modes ;-)
>> Hmmm. I suppose I could make (cpio-mode) a function instead of a mode,
> I think using buffer-swap-text, you should be able to fairly easily make
> it so that cpio-mode is a proper major mode (e.g. doesn't change
> current-buffer) and yet moves the current buffer's contents to some
> auxiliary buffer and puts the dired-style interface in the current buffer.
> (and setup a change-major-mode-hook to reverse this if the user decides
> to change the major mode to something else like fundamental-mode).
>         Stefan

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

reply via email to

[Prev in Thread] Current Thread [Next in Thread]