GNU bug report logs - #7145
elisp-code behaves differently after byte-compilation

Previous Next

Package: emacs;

Reported by: "Markus Sauermann" <mhoram <at> gmx.de>

Date: Sat, 2 Oct 2010 01:57:01 UTC

Severity: minor

Tags: wontfix

Done: Lars Magne Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Markus Sauermann <mhoram <at> gmx.de>
To: Chong Yidong <cyd <at> stupidchicken.com>
Cc: 7145 <at> debbugs.gnu.org, Andreas Schwab <schwab <at> linux-m68k.org>
Subject: bug#7145: elisp-code behaves differently after byte-compilation
Date: Tue, 05 Oct 2010 19:37:03 +0200
Hi,

Am 03.10.2010 07:12, schrieb Chong Yidong:
> 
> I think we're just going to have to ask people not to do that...
> 

it looks like an undocumented feature ;-)
Here is a suggestion for a patch for the documentation (trunk of emacs
Bazaar repository)

--- BEGIN ---
=== modified file 'doc/lispref/objects.texi'
--- doc/lispref/objects.texi	2010-08-19 23:23:13 +0000
+++ doc/lispref/objects.texi	2010-10-05 18:00:58 +0000
@@ -1999,6 +1999,17 @@
      @result{} nil
 @end group
 @end example
+
+Be aware that byte-compiling a comparison of strings with @code{eq}
+might give unexpected results.
+
+@example
+@group
+(funcall (byte-compile (lambda () (let ((foo "bar"))
+                                    (eq foo "bar")))))
+     @result{} t
+@end group
+@end example
 @end defun

 @defun equal object1 object2

--- END ---

Regards
Markus




This bug report was last modified 13 years and 316 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.