Subject: 24.0.50; Case and search problems in unibyte buffers

From: [email-masked]
Date: Mon, 29 Mar 2010 22:48:08 +0200

http://lists.gnu.org/archive/html/help-gnu-emacs/2010-03/msg00246.html

This correctly finds a \377 character in a unibyte buffer:

    (let ((case-fold-search nil)) (search-forward "\377"))

This fails to match \377 and actually finds \277 instead:

    (let ((case-fold-search t)) (search-forward "\377"))

`downcase' behaves strangely too:

    (let ((default-enable-multibyte-characters nil))
      (with-temp-buffer
        (downcase 255)))
    => 4194303

These problems exist in trunk and Emacs 23, and did not occur in
Emacs 22.