From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lawrence Mitchell Newsgroups: gmane.emacs.bugs,gmane.emacs.pretest.bugs Subject: bug#1187: 23.0.60; Cannot read vline.el - invalid read syntax Date: Fri, 17 Oct 2008 13:30:24 +0100 Organization: funfunfun Message-ID: References: <00f801c92fd5$54f26100$c2b22382@us.oracle.com> Reply-To: Lawrence Mitchell , 1187@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1224247941 14350 80.91.229.12 (17 Oct 2008 12:52:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 17 Oct 2008 12:52:21 +0000 (UTC) Cc: emacs-pretest-bug@gnu.org To: bug-gnu-emacs@gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Oct 17 14:53:18 2008 connect(): Connection refused Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KqopN-0008FW-WF for geb-bug-gnu-emacs@m.gmane.org; Fri, 17 Oct 2008 14:53:15 +0200 Original-Received: from localhost ([127.0.0.1]:40712 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KqooI-00055E-Dt for geb-bug-gnu-emacs@m.gmane.org; Fri, 17 Oct 2008 08:52:06 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KqomN-0004TM-IZ for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 08:50:07 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KqomL-0004S0-Bw for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 08:50:06 -0400 Original-Received: from [199.232.76.173] (port=46091 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KqomK-0004Ri-SD for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 08:50:04 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:37494) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KqomK-0000Zk-5j for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 08:50:05 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9HCo0dL031114; Fri, 17 Oct 2008 05:50:00 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id m9HCe4n7028885; Fri, 17 Oct 2008 05:40:04 -0700 X-Loop: don@donarmstrong.com Resent-From: Lawrence Mitchell Original-Sender: news Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Fri, 17 Oct 2008 12:40:04 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1187 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by submit@emacsbugs.donarmstrong.com id=B.122424665327536 (code B ref -1); Fri, 17 Oct 2008 12:40:04 +0000 Original-Received: (at submit) by emacsbugs.donarmstrong.com; 17 Oct 2008 12:30:53 +0000 Original-Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m9HCUkIu027530 for ; Fri, 17 Oct 2008 05:30:48 -0700 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KqoTe-0003z1-2l for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 08:30:46 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KqoTc-0003yA-9i for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 08:30:45 -0400 Original-Received: from [199.232.76.173] (port=60491 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KqoTc-0003y3-4M for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 08:30:44 -0400 Original-Received: from main.gmane.org ([80.91.229.2]:58195 helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KqoTc-0004iu-6Q for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 08:30:44 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1KqoTW-0006XS-J8 for bug-gnu-emacs@gnu.org; Fri, 17 Oct 2008 12:30:38 +0000 Original-Received: from lamacq.ph.ed.ac.uk ([129.215.72.156]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 17 Oct 2008 12:30:38 +0000 Original-Received: from wence by lamacq.ph.ed.ac.uk with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 17 Oct 2008 12:30:38 +0000 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: bug-gnu-emacs@gnu.org Original-Lines: 121 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lamacq.ph.ed.ac.uk Mail-Copies-To: nobody User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) Cancel-Lock: sha1:tMyXx4Tr1Hfjbzr97Bhhj7HqvnQ= X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-MIME-Autoconverted: from 8bit to quoted-printable by rzlab.ucr.edu id m9HCo0dL031114 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Resent-Date: Fri, 17 Oct 2008 08:50:06 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:21598 gmane.emacs.pretest.bugs:23247 Archived-At: Drew Adams wrote: > Library vline.el can be read fine in Emacs 22, but Emacs 23 raises an > error, saying Invalid read syntax: "?". The following sequence of events works for me in GNU Emacs 23.0.60.4 (i686-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of 2008-10-07 on lamacq.ph.ed.ac.uk $ wget http://www.emacswiki.org/cgi-bin/emacs/download/vline.el \ -O /tmp/vline.el $ LANG=3DC emacs -Q --eval '(load-file "/tmp/vline.el")' LANG=3DC so that current-language-environment is "ASCII" and default-buffer-file-coding-system is nil. Successfully prints: Loading /tmp/vline.el (source)...done > In GNU Emacs 23.0.60.1 (i386-mingw-nt5.1.2600) > of 2008-10-03 on LENNART-69DE564 > Windowing system distributor `Microsoft Corp.', version 5.1.2600 > configured using `configure --with-gcc (3.4) --no-opt --cflags -Ic:/g/i= nclude > -fno-crossjumping' > Important settings: > value of $LC_ALL: nil > value of $LC_COLLATE: nil > value of $LC_CTYPE: nil > value of $LC_MESSAGES: nil > value of $LC_MONETARY: nil > value of $LC_NUMERIC: nil > value of $LC_TIME: nil > value of $LANG: ENU ^^^ this seems to be the culprit. LANG=3DENU is an unknown locale here but if LANG=3Den_GB such that default-buffer-file-coding-system is iso-latin-1-unix then the section of the file that causes problems is: (memq char '(?\t ?=E3=80=80)) where the second character is: | character: =E3=80=80 (12288, #o30000, #x3000) | preferred charset: unicode (Unicode (ISO10646)) | code point: 0x3000 | syntax: _ which means: symbol | category: c:Chinese h:Korean j:Japanese | |:While filling, we can break a line at this character. | buffer code: #xE3 #x80 #x80 | file code: #xE3 #x80 #x80 (encoded by coding system utf-8-unix) | display: by this font (glyph code) | xft:-unknown-Kochi Gothic-normal-normal-normal-*-15-*-*-*-*-0-iso10= 646-1 (#x6F3) | Character code properties: customize what to show | name: IDEOGRAPHIC SPACE | general-category: Zs (Separator, Space) | decomposition: ( 32) ( ' ') The difference between emacs-21.3 and emacs 23 appears to be that the former ignores the two extra bytes when reading in latin-1 but emacs 23 does not: $ od -c /tmp/f 0000000 ? 343 200 200 0000004 Emacs 23: (let ((coding-system-for-read 'iso-latin-1) ret) (with-temp-buffer (insert-file-contents "/tmp/f") (setq ret (read (current-buffer)))) (insert ret)) =3D> (invalid-read-syntax "?") read(#) ---- (let ((coding-system-for-read 'utf-8) ret) (with-temp-buffer (insert-file-contents "/tmp/f") (setq ret (read (current-buffer)))) (insert ret)) =3D> IDEOGRAPHIC SPACE is inserted correctly Emacs 21.3 (let ((coding-system-for-read 'iso-latin-1) ret) (with-temp-buffer (insert-file-contents "/tmp/f") (setq ret (read (current-buffer)))) (insert ret)) =3D> =C3=A3 ; LATIN SMALL LETTER A WITH TILDE is inserted. ----- (let ((coding-system-for-read 'utf-8) ret) (with-temp-buffer (insert-file-contents "/tmp/f") (setq ret (read (current-buffer)))) (insert ret)) =3D> IDEOGRAPHIC SPACE is inserted correctly --=20 Lawrence Mitchell