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

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

bug#26796: 26.0.50; (2 characters) is usually wrong


From: Lars Ingebrigtsen
Subject: bug#26796: 26.0.50; (2 characters) is usually wrong
Date: Sat, 06 May 2017 12:45:45 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

Eli Zaretskii <eliz@gnu.org> writes:

>> Perhaps saying "(2 bytes)" will be more helpful?
>
> I really doubt that: Emacs users tend to think in terms of characters
> than in terms of bytes.

But this is questionable, at least:

(with-temp-buffer (set-buffer-multibyte nil) (insert-file-contents "~/rms.jpg") 
(write-region (point-min) (point-max) "/tmp/a.jpg"))
Wrote ‘/tmp/a.jpg’ (889 characters)

There are no characters in a JPEG file; it's all bytes.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

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