From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#15692: 24.3.50; rcirc activity mode-line indicator gets cleared automatically Date: Wed, 23 Oct 2013 16:10:25 -0400 Message-ID: References: <87hac89z83.fsf@tsdh.uni-koblenz.de> <87d2mw9wov.fsf@tsdh.uni-koblenz.de> <878uxk9jeo.fsf@tsdh.uni-koblenz.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1382559082 28694 80.91.229.3 (23 Oct 2013 20:11:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 23 Oct 2013 20:11:22 +0000 (UTC) Cc: 15692@debbugs.gnu.org, Leo Liu To: Tassilo Horn Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Oct 23 22:11:25 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VZ4m5-0002TY-2I for geb-bug-gnu-emacs@m.gmane.org; Wed, 23 Oct 2013 22:11:25 +0200 Original-Received: from localhost ([::1]:51274 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VZ4m4-0008K2-Il for geb-bug-gnu-emacs@m.gmane.org; Wed, 23 Oct 2013 16:11:24 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53363) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VZ4lt-0008EP-Qm for bug-gnu-emacs@gnu.org; Wed, 23 Oct 2013 16:11:21 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VZ4li-0001at-Ql for bug-gnu-emacs@gnu.org; Wed, 23 Oct 2013 16:11:13 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:52949) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VZ4li-0001ak-Ml for bug-gnu-emacs@gnu.org; Wed, 23 Oct 2013 16:11:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1VZ4li-0000rq-1g for bug-gnu-emacs@gnu.org; Wed, 23 Oct 2013 16:11:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 23 Oct 2013 20:11:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15692 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 15692-submit@debbugs.gnu.org id=B15692.13825590293288 (code B ref 15692); Wed, 23 Oct 2013 20:11:01 +0000 Original-Received: (at 15692) by debbugs.gnu.org; 23 Oct 2013 20:10:29 +0000 Original-Received: from localhost ([127.0.0.1]:38732 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VZ4lB-0000qx-AI for submit@debbugs.gnu.org; Wed, 23 Oct 2013 16:10:29 -0400 Original-Received: from pruche.dit.umontreal.ca ([132.204.246.22]:37146) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VZ4l8-0000qo-Rt for 15692@debbugs.gnu.org; Wed, 23 Oct 2013 16:10:27 -0400 Original-Received: from faina.iro.umontreal.ca (lechon.iro.umontreal.ca [132.204.27.242]) by pruche.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id r9NKAQSr010814; Wed, 23 Oct 2013 16:10:26 -0400 Original-Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id DFAE9B4152; Wed, 23 Oct 2013 16:10:25 -0400 (EDT) In-Reply-To: <878uxk9jeo.fsf@tsdh.uni-koblenz.de> (Tassilo Horn's message of "Wed, 23 Oct 2013 16:00:31 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV4740=0 X-NAI-Spam-Version: 2.3.0.9362 : core <4740> : inlines <172> : streams <1061172> : uri <1574171> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:79554 Archived-At: >> No. It wouldn't be very hard to add, tho. > It's definititely not the first time where I could need something like > that. Maybe it could also be a bit more general, e.g., one could add a > watcher function to a symbol that's called whenever the symbol-value is > set. The way to implement it, I think is to take the "read-only" bit of symbols, and extend it with a third value ("watched"). So assignment to such a variable would be a variation of "read-only", except that instead of signally an error, it would call some Elisp code. The point being that the "normal execution path" can stay unchanged, so we don't slow down normal execution. Of course, it wouldn't work on those Elisp variable that are defined in C (i.e. defined via DEFVAR_LISP, DEFVAR_BOOL, or DEFVAR_INT), where the value can be directly changed by the C code without going through those tests. Kind of like advice on subrs. Stefan