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

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

bug#20334: What does all-completions with COLLECTION == obarray return?


From: Stefan Monnier
Subject: bug#20334: What does all-completions with COLLECTION == obarray return?
Date: Wed, 15 Apr 2015 11:14:16 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

> I guess this should not happen, so it is a bug in Emacs in think.

Indeed.  Thanks for the test case.  I reduced it to:

   (progn
     (intern "Bahá'í Date") ;this happens when requiring org
     (facep "Bahá'í Date")
     ;; Test if "Bahá'í Date" is the name of more than one interned symbol
     (let ((ss nil))
       (mapatoms (lambda (s) (when (string= (symbol-name s) "Bahá'í Date")
                            (push s ss)))
              nil)
       (length ss)))

So the patch below fixes it, but it points at a problem in the
C function `intern' which I haven't tracked down yet.


        Stefan


diff --git a/src/xfaces.c b/src/xfaces.c
index 9f8a816..d079be8 100644
--- a/src/xfaces.c
+++ b/src/xfaces.c
@@ -1822,7 +1822,8 @@ resolve_face_name (Lisp_Object face_name, bool signal_p)
   Lisp_Object tortoise, hare;
 
   if (STRINGP (face_name))
-    face_name = intern (SSDATA (face_name));
+    /* face_name = intern (SSDATA (face_name)); */
+    face_name = Fintern (face_name, Qnil);
 
   if (NILP (face_name) || !SYMBOLP (face_name))
     return face_name;





reply via email to

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