help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: How to view raw text in Emacs?


From: Eli Zaretskii
Subject: Re: How to view raw text in Emacs?
Date: Fri, 06 Apr 2018 15:59:12 +0300

> From: Ben Bacarisse <address@hidden>
> Date: Fri, 06 Apr 2018 11:29:12 +0100
> 
> >>   If Emacs already has a buffer which is visiting the file, you
> >>   get the existing buffer, regardless of whether it was created
> >>   literally or not.
> >
> > "Same buffer" doesn't mean the same contents.  When the file is
> > already being visited, you can get the same buffer, but its contents
> > will be erased and populated anew with literally what's in the file,
> > without any conversions.
> 
> That paragraph started with the sentence "You cannot absolutely rely on
> this function to result in visiting the file literally."

It no longer says that, I fixed that misleading text.

> but I think the warning is specifically about using
> find-file-literally in a program

You shouldn't use that function in a program, you should use
insert-file-contents-literally instead.

> when called interactively (at least in 25.1.1) I get a warning that
> emacs can only visit a file in one way at a time and I am prompted
> whether to "revisit" the file (so to speak) or take the existing
> buffer.

Yes, and that's the important part the doc string failed to tell.  Now
it does.



reply via email to

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