[ESS-bugs] noweb-mode fails to find chunks containing [[...]] in title
Rafael Laboissiere
rafael at debian.org
Wed Aug 20 12:47:55 CEST 2008
* Martin Maechler <maechler at stat.math.ethz.ch> [2008-08-20 12:00]:
> >>>>> "RL" == Rafael Laboissiere <rafael at debian.org>
> >>>>> on Tue, 19 Aug 2008 17:14:23 +0200 writes:
>
> RL> * A.J. Rossini <blindglobe at gmail.com> [2008-08-19 13:40]:
> >> I don't think the patch came through? Could you send it personally
> >> to me and I'll review/apply, or if small, just insert into email?
>
> RL> Sending it again.
>
> so Tony now probably got it (since you addressed him
> explicitly).
>
> Note that the mailing list software removes unspecified binary
> attachments sent to ESS-bugs / ESS-core
>
> You could send attachments if you used MIME-type 'text/plain'.
> Inserting into the e-mail as Tony had suggested would have
> worked well also.
Thanks for the explanation. Let us see if I can set the MIME-type correctly
with mutt this time.
Cheers,
--
Rafael
-------------- next part --------------
--- noweb-mode.el-orig 2008-08-16 17:15:14.000000000 +0200
+++ noweb-mode.el 2008-08-16 18:35:48.000000000 +0200
@@ -1179,7 +1179,7 @@
(setq chunk-name (match-string 1))
(widen)
(goto-char (point-min))
- (re-search-forward (concat "^<<" chunk-name ">>=") nil t)
+ (re-search-forward (concat "^<<" (regexp-quote chunk-name) ">>=") nil t)
(beginning-of-line 2)
(setq mode (noweb-in-mode-line))
(if (functionp mode)
@@ -1276,7 +1276,7 @@
(re-search-backward "^[ \t]*<<\\(.*\\)>>=" nil t)
(setq chunk-name (match-string 1))
(goto-char (point-min))
- (re-search-forward (concat "^<<" chunk-name ">>=") nil t)
+ (re-search-forward (concat "^<<" (regexp-quote chunk-name) ">>=") nil t)
(beginning-of-line 2))
;; remove mode-line, if there is one
(if (noweb-in-mode-line)
@@ -1347,13 +1347,13 @@
(let ((chunk-name (buffer-substring-no-properties
(match-beginning 2)
(match-end 2))))
- (re-search-backward (concat "<<" chunk-name ">>") nil t))
+ (re-search-backward (concat "<<" (regexp-quote chunk-name) ">>") nil t))
(if (and (<= (match-end 2) (point))
(> (+ 2 (match-end 2)) (point)))
(let ((chunk-name (buffer-substring-no-properties
(match-beginning 2)
(match-end 2))))
- (re-search-forward (concat "<<" chunk-name ">>") nil t)))))))
+ (re-search-forward (concat "<<" (regexp-quote chunk-name) ">>") nil t)))))))
;;; Debugging
@@ -1526,7 +1526,7 @@
(let ((chunk-name (match-string 1)))
(widen)
(goto-char (point-min))
- (re-search-forward (concat "^<<" chunk-name ">>=") nil t)
+ (re-search-forward (concat "^<<" (regexp-quote chunk-name) ">>=") nil t)
(beginning-of-line 2)
(while (looking-at ".*-\*-.*-\*-")
(let ((this-line (buffer-substring-no-properties
@@ -1649,7 +1649,7 @@
(save-excursion
(setq thread-name-re
(concat "<<"
- (match-string 2)
+ (regexp-quote (match-string 2))
">>="))
(setq pre-chunk (match-string 1))
(if prefix-string
More information about the ESS-bugs
mailing list