emacs-devel
[Top][All Lists]
Advanced

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

Re: Compiling Elisp to a native code with a GCC plugin


From: Stephen J. Turnbull
Subject: Re: Compiling Elisp to a native code with a GCC plugin
Date: Sat, 18 Sep 2010 23:19:11 +0900

Eli Zaretskii writes:

 > However, AFAIK Emacs always makes a unibyte string if all the
 > characters are pure ASCII.  So this does not matter in practice.

That's true in Stefan's personal Emacs, AIUI, but otherwise I bet aset
on a multibyte string can turn it into pure ASCII.

 > > (defun string-byte-count (s)
 > >   (length (if (string-multibyte-p s) (encode-coding-string s
 > >   'utf-8) s)))
 > 
 > See above: this is not accurate.

I don't understand what "above" you're referring to.  Unless maybe you
mean because in unibyte strings the byte count is negative?



reply via email to

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