[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Args out of range: #<buffer test.org>, 0, 1
From: |
Nicolas Richard |
Subject: |
Re: [O] Args out of range: #<buffer test.org>, 0, 1 |
Date: |
Tue, 13 Jan 2015 22:58:41 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
Sebastien Vauban <sva-news-D0wtAvR13HarG/address@hidden>
writes:
> This still leaves me with one question: how do we reproduce the problem?
> What's the trigger for it?
Mostly luck. i.e. you need to have called a function that callled
string-match on a string, with a regexp containing (at least) 4 grouping
constructs, and the 4th matched at the beginning of that string
(beginning position 0) but only one character (end position 1) [1]. And
then later call org-babel-demarcate-block. Between the two, many things
may have happened as long as the match data was preserved.
[1] I gave an example of such a call to string-match -- my example
wasn't super useful I admit. In your case, it could be anything : not
necessarily an org function. Many functions use string-match internally.
> PS- @NicolasG, thanks for fixing it...
And also thanks for mentionning org-babel-src-block-regexp... and
completely rewriting org-babel-where-is-src-block-head. Very impressive!
--
Nicolas.