From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Better parse-partial-sexp; multiple major modes Date: Sun, 31 Aug 2008 14:17:27 -0400 Message-ID: References: <15CDB3E4-0A1B-446B-BA49-E2C91E6FAD9D@merrillpress.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1220206666 31001 80.91.229.12 (31 Aug 2008 18:17:46 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 31 Aug 2008 18:17:46 +0000 (UTC) Cc: emacs-devel@gnu.org To: Daniel Colascione Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Aug 31 20:18:40 2008 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.50) id 1KZrVX-00072F-5Q for ged-emacs-devel@m.gmane.org; Sun, 31 Aug 2008 20:18:39 +0200 Original-Received: from localhost ([127.0.0.1]:34147 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KZrUY-0000fm-6C for ged-emacs-devel@m.gmane.org; Sun, 31 Aug 2008 14:17:38 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KZrUT-0000ey-IK for emacs-devel@gnu.org; Sun, 31 Aug 2008 14:17:33 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KZrUS-0000d2-2k for emacs-devel@gnu.org; Sun, 31 Aug 2008 14:17:33 -0400 Original-Received: from [199.232.76.173] (port=38728 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KZrUR-0000cu-VE for emacs-devel@gnu.org; Sun, 31 Aug 2008 14:17:31 -0400 Original-Received: from ironport2-out.pppoe.ca ([206.248.154.182]:47182 helo=ironport2-out.teksavvy.com) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KZrUR-000735-No for emacs-devel@gnu.org; Sun, 31 Aug 2008 14:17:31 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AjYFAK99ukhFxJrH/2dsb2JhbACBZbVMgWmBBw X-IronPort-AV: E=Sophos;i="4.32,302,1217822400"; d="scan'208";a="26172615" Original-Received: from 69-196-154-199.dsl.teksavvy.com (HELO ceviche.home) ([69.196.154.199]) by ironport2-out.teksavvy.com with ESMTP; 31 Aug 2008 14:17:29 -0400 Original-Received: by ceviche.home (Postfix, from userid 20848) id D84CAB41E9; Sun, 31 Aug 2008 14:17:27 -0400 (EDT) In-Reply-To: <15CDB3E4-0A1B-446B-BA49-E2C91E6FAD9D@merrillpress.com> (Daniel Colascione's message of "Sun, 31 Aug 2008 05:39:56 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. 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:103328 Archived-At: > Such a thing would have to live on the C side of things, right? (With the > proliferation of with-this and inhibit-that options available to Lisp, > I don't see how one can easily and robustly catch all buffer > modification. Not to mention that no matter which of before-change- > functions and after-change-functions you used, you could still race against > other functions using the same facility.) In theory, that might be true, but it's not been that big of a deal for now. And of course moving it to C would help some but it won't solve all those problems magically. > Anyway, this scheme is: > 1) Robust - no messing around with variables, no tweaking fontification > 2) Backwards compatible - a major-mode doesn't need to know it's being used > this way > 3) Versatile - you can compose arbitrary modes this way, even recursively > 4) Conceptually simple (I hope) I don't think it's possible to get 1 and 2 together, really. Stefan