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: generic buffer parsing cache data Date: Sun, 01 Jul 2007 08:52:23 -0400 Message-ID: References: <200707010038.23072.pogonyshev@gmx.net> <468794AB.20401@gmx.at> <200707011516.31959.pogonyshev@gmx.net> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1183294353 26352 80.91.229.12 (1 Jul 2007 12:52:33 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 1 Jul 2007 12:52:33 +0000 (UTC) Cc: martin rudalics , emacs-devel@gnu.org To: Paul Pogonyshev Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Jul 01 14:52:31 2007 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 1I4yul-00079i-Nm for ged-emacs-devel@m.gmane.org; Sun, 01 Jul 2007 14:52:31 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I4yuk-0004sJ-VS for ged-emacs-devel@m.gmane.org; Sun, 01 Jul 2007 08:52:30 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1I4yug-0004ob-J5 for emacs-devel@gnu.org; Sun, 01 Jul 2007 08:52:26 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1I4yuf-0004mm-IV for emacs-devel@gnu.org; Sun, 01 Jul 2007 08:52:25 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I4yuf-0004mf-Ad for emacs-devel@gnu.org; Sun, 01 Jul 2007 08:52:25 -0400 Original-Received: from tomts43.bellnexxia.net ([209.226.175.110] helo=tomts43-srv.bellnexxia.net) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1I4yue-0003Ju-Sg for emacs-devel@gnu.org; Sun, 01 Jul 2007 08:52:25 -0400 Original-Received: from pastel.home ([70.53.192.43]) by tomts43-srv.bellnexxia.net (InterMail vM.5.01.06.13 201-253-122-130-113-20050324) with ESMTP id <20070701125224.GSIW5730.tomts43-srv.bellnexxia.net@pastel.home> for ; Sun, 1 Jul 2007 08:52:24 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id C687282CC; Sun, 1 Jul 2007 08:52:23 -0400 (EDT) In-Reply-To: <200707011516.31959.pogonyshev@gmx.net> (Paul Pogonyshev's message of "Sun\, 1 Jul 2007 15\:16\:31 +0300") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1.50 (gnu/linux) X-detected-kernel: Solaris 8 (1) 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:74103 Archived-At: >> > I propose that each point position could have "cached parsing data". >> > This would be an alist indexed with cache data identifier. >> Have you experimented with `syntax-ppss'? > I propose to add something generic. For instance, Python mode needs to > know indentation level of blocks. It seems that `syntax-ppss` doesn't > return it at all. And adding everything that might ever be needed by > some XYZ mode seems counter-productive and complicates an already complex > function and its return value. 100% agreement. This said, I think it might make sense to combine the two so that syntax-ppss returns not just the parse-partial-sexp state but also some mode-specific data. At least it's been in my TODO list for a while now. > As a side note, I was told somewhen that `parse-partial-sexp` is not > limited to Lisp syntax. How about this amendment to documentation? Sounds good, Stefan