* bug#5672: 23.1; (intern-soft "") returns non-nil
@ 2010-03-02 23:28 Katsumi Yamaoka
2010-03-03 0:40 ` Andreas Schwab
2010-03-03 4:15 ` Stefan Monnier
0 siblings, 2 replies; 5+ messages in thread
From: Katsumi Yamaoka @ 2010-03-02 23:28 UTC (permalink / raw)
To: 5672
Hi,
There's a program assuming (intern-soft STR) always return nil
if STR is the null string. It works in Emacs 22, but doesn't in
Emacs 23. That problem is easily solved by modifying the code
into: (unless (equal STR "") (intern-soft STR))
However, isn't it an Emacs 23 bug? It's not so serious though.
It does not happen in Emacs that is launched using the arg -Q
but happens after loading the ~/.emacs file. I found at least
`internal-set-lisp-face-attribute' that `set-face-attribute'
uses does intern "". For instance:
$ emacs -Q
(intern-soft "")
=> nil
(internal-set-lisp-face-attribute
'bold :font
"-*-gothic-bold-r-*-*-16-*-*-*-*-*-iso8859-1"
0)
=> bold
(intern-soft "")
=>
I don't know what in `internal-set-lisp-face-attribute' does it.
Regards,
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#5672: 23.1; (intern-soft "") returns non-nil
2010-03-02 23:28 bug#5672: 23.1; (intern-soft "") returns non-nil Katsumi Yamaoka
@ 2010-03-03 0:40 ` Andreas Schwab
2010-03-03 4:15 ` Stefan Monnier
1 sibling, 0 replies; 5+ messages in thread
From: Andreas Schwab @ 2010-03-03 0:40 UTC (permalink / raw)
To: Katsumi Yamaoka; +Cc: 5672
Katsumi Yamaoka <yamaoka@jpl.org> writes:
> I don't know what in `internal-set-lisp-face-attribute' does it.
Inside font_parse_xlfd, where the adstyle field is usually empty.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#5672: 23.1; (intern-soft "") returns non-nil
2010-03-02 23:28 bug#5672: 23.1; (intern-soft "") returns non-nil Katsumi Yamaoka
2010-03-03 0:40 ` Andreas Schwab
@ 2010-03-03 4:15 ` Stefan Monnier
2010-03-03 4:50 ` Katsumi Yamaoka
1 sibling, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2010-03-03 4:15 UTC (permalink / raw)
To: Katsumi Yamaoka
> There's a program assuming (intern-soft STR) always return nil
> if STR is the null string.
That is an invalid assumption.
> It works in Emacs 22, but doesn't in Emacs 23.
Try it with Emacs-22 after doing (intern ""), you'll get the same result
as in Emacs-23.
> However, isn't it an Emacs 23 bug?
No.
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#5672: 23.1; (intern-soft "") returns non-nil
2010-03-03 4:15 ` Stefan Monnier
@ 2010-03-03 4:50 ` Katsumi Yamaoka
2010-03-03 15:18 ` Stefan Monnier
0 siblings, 1 reply; 5+ messages in thread
From: Katsumi Yamaoka @ 2010-03-03 4:50 UTC (permalink / raw)
To: 5672
>>>>> Stefan Monnier wrote:
>> There's a program assuming (intern-soft STR) always return nil
>> if STR is the null string.
> That is an invalid assumption.
Agreed.
>> It works in Emacs 22, but doesn't in Emacs 23.
> Try it with Emacs-22 after doing (intern ""), you'll get the same result
> as in Emacs-23.
I've already verified it but that's the case of doing it purposely,
whereas Emacs 23's case doesn't seem so. That's why I reported it.
>> However, isn't it an Emacs 23 bug?
> No.
Ok.
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#5672: 23.1; (intern-soft "") returns non-nil
2010-03-03 4:50 ` Katsumi Yamaoka
@ 2010-03-03 15:18 ` Stefan Monnier
0 siblings, 0 replies; 5+ messages in thread
From: Stefan Monnier @ 2010-03-03 15:18 UTC (permalink / raw)
To: Katsumi Yamaoka; +Cc: 5672
>>> It works in Emacs 22, but doesn't in Emacs 23.
>> Try it with Emacs-22 after doing (intern ""), you'll get the same result
>> as in Emacs-23.
> I've already verified it but that's the case of doing it purposely,
Right, but it could be done purposefully by some random other package.
> whereas Emacs 23's case doesn't seem so. That's why I reported it.
It's not done "to define the empty symbol", so in a sense it's not
done "purposefully", but it's not the result of a bug either.
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-03-03 15:18 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-02 23:28 bug#5672: 23.1; (intern-soft "") returns non-nil Katsumi Yamaoka
2010-03-03 0:40 ` Andreas Schwab
2010-03-03 4:15 ` Stefan Monnier
2010-03-03 4:50 ` Katsumi Yamaoka
2010-03-03 15:18 ` Stefan Monnier
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).