[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Supplying a default initial STATE to parse-partial-sexp. What about elt.
From: |
Alan Mackenzie |
Subject: |
Supplying a default initial STATE to parse-partial-sexp. What about elt. 9? |
Date: |
Tue, 30 Jun 2009 16:20:37 +0000 |
User-agent: |
Mutt/1.5.9i |
Hi, Emacs!
In a function, I want to parse-partial-sexp through a buffer,
successively feeding its result back as the STATE parameter of the next
call.
To avoid an irritating special case, I'd like to initialize the state to
a default value, rather than passing in nil. Something like:
(let ((pps-state '(0 nil 0 nil nil nil 0 nil nil nil)))
;; 0 1 2 3 4 5 6 7 8 9
....)
However, this leaves me a bit uneasy about the 9th element, which is
documented as "Intermediate data for continuation of parsing (subject to
change)". Is it valid to set elt 9 as nil, or will this cause some sort
of malfunction or signal in parse-partial-sexp?
Thanks in advance!
--
Alan Mackenzie (Nuremberg, Germany).
- Supplying a default initial STATE to parse-partial-sexp. What about elt. 9?,
Alan Mackenzie <=