From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juanma Barranquero Newsgroups: gmane.emacs.devel Subject: Re: Delayed warnings Date: Mon, 21 Mar 2011 21:19:29 +0100 Message-ID: References: <4D8705CA.1020300@gmx.at> <4D874FF3.9010606@gmx.at> <4D8793B1.2040701@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1300738983 17854 80.91.229.12 (21 Mar 2011 20:23:03 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 21 Mar 2011 20:23:03 +0000 (UTC) Cc: Emacs developers To: martin rudalics Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Mar 21 21:22:56 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Q1lcp-000886-Ip for ged-emacs-devel@m.gmane.org; Mon, 21 Mar 2011 21:22:51 +0100 Original-Received: from localhost ([127.0.0.1]:36541 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q1laT-0005qE-Mu for ged-emacs-devel@m.gmane.org; Mon, 21 Mar 2011 16:20:25 -0400 Original-Received: from [140.186.70.92] (port=47810 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q1laI-0005kJ-EU for emacs-devel@gnu.org; Mon, 21 Mar 2011 16:20:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q1laD-0000GB-Vk for emacs-devel@gnu.org; Mon, 21 Mar 2011 16:20:14 -0400 Original-Received: from mail-yi0-f41.google.com ([209.85.218.41]:58710) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q1laD-0000Fa-Nj for emacs-devel@gnu.org; Mon, 21 Mar 2011 16:20:09 -0400 Original-Received: by yib2 with SMTP id 2so3256582yib.0 for ; Mon, 21 Mar 2011 13:20:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type:content-transfer-encoding; bh=A0EqxxLlDxwsNAkFDd+3Xkcn0bJhcQPX+k98tIYaH/o=; b=ZjBGOkbeFGrRBsAImDIh/MeXU0Z7MQ+tXGZEey8T1+UKwTG4UO8B3UXKQZIioDHk1J V9uT+DUPXnTtV4dMw1MeNkvDzYiLhQSOMtYTV8PDjr3n97icGvzce8j9zVTp0Wlofto1 Q8oLaXRuhnMpmG3502xFLmf027IScgJqV0p6Y= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=jS6reNyAF713Mt1eP9u1LRMesbbHJ0URTztBh34VnwrLL4WNQDQ6Sj9apX0fKfGLac wfWYdzaudaRnZvMUWHmvSz3+PHYaHqKbw/ZEpRgupAWLrw4hN5t6njGDqlvak/3OgeWV SJMjB19OKXHMj1U3ue13jmzbkwE+D8+mrpanw= Original-Received: by 10.236.168.37 with SMTP id j25mr5945894yhl.3.1300738809157; Mon, 21 Mar 2011 13:20:09 -0700 (PDT) Original-Received: by 10.147.34.11 with HTTP; Mon, 21 Mar 2011 13:19:29 -0700 (PDT) In-Reply-To: <4D8793B1.2040701@gmx.at> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.218.41 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:137496 Archived-At: On Mon, Mar 21, 2011 at 19:06, martin rudalics wrote: > I thought you had something in mind like `display-warning' tailored for > the case that `display-warning' isn't callable for some reason. That's more or less. I wanted to call display-warning, found that it was too soon, and looked for a way to delay it. > A `display-delayed-warnings' function run after `post-command-hook' more > or less from where `deferred-action-function' was or is called. =C2=A0Tha= t > function would display all (appropriately filtered) warnings that have > accumulated in the `delayed-warnings' list since the last time it was > called and reset the list to nil. =C2=A0Ideally, `display-delayed-warning= s' > would call `display-warning' for each element of `delayed-warnings'. Yes, like the malloc low-memory warning code does. Fine by me. The problem I wanted to tackle was warning about default HOME, not designing a delayed warning facility :-) Only I would process `display-delayed-warnings' in reverse, so C code can add with Vdisplay_delayed_warnings =3D Fcons (..., Vdisplay_delayed_warnings); but the user still gets the warnings in order. =C2=A0 =C2=A0 Juanma