* Question from the distant past on posting-styles
@ 2017-04-28 9:26 Andrew Cohen
0 siblings, 0 replies; only message in thread
From: Andrew Cohen @ 2017-04-28 9:26 UTC (permalink / raw)
To: ding
OK, I have a question that perhaps someone from the old days might know
about. In gnus-msg.el (gnus-setup-message) there is a cryptic comment
from "drv":
;; #### FIXME: for a reason that I did not manage to identify yet,
;; the variable `gnus-newsgroup-name' does not honor a dynamically
;; scoped or setq'ed value from a caller like `C-u gnus-summary-mail'.
;; After evaluation of @forms below, it gets the value we actually want
;; to override, and the posting styles are used. For that reason, I've
;; added an optional argument to `gnus-configure-posting-styles' to
;; make sure that the correct value for the group name is used. -- drv
and corresponding comments in gnus-group-mail, gnus-group-news, and
gnus-summary-mail-other-window:
;; We can't `let' gnus-newsgroup-name here, since that leads
;; to local variables leaking.
I can't quite understand the comments, but I tried just changing things
to use 'let and it seems to work (I tried some posting-styles and they
were picked up correctly).
The use of setq seems to stomp all over the buffer-local values of
gnus-newsgroup-name. Usually this doesn't cause problems but I finally
traced a rare bug to this (I had a case where setting up a message
buffer fails because of a problem with bbdb; then the original value of
gnus-newsgroup-name doesn't get restored and this causes some problems
down the road).
I would like to change all this to use let and dispense with the
setqs. Does anybody remember the issue?
Best,
Andy
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-04-28 9:26 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-28 9:26 Question from the distant past on posting-styles Andrew Cohen
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 NNTP newsgroup(s).