[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] [RFC] Org version of the Org manual
From: |
Achim Gratz |
Subject: |
Re: [O] [RFC] Org version of the Org manual |
Date: |
Fri, 22 Mar 2013 17:46:19 +0100 |
User-agent: |
Mozilla/5.0 (Windows NT 5.1; rv:17.0) Gecko/20130307 Thunderbird/17.0.4 |
Am 22.03.2013 15:22, schrieb Nicolas Goaziou:
Actually the code I pasted is wrong, I meant:
(split-string
(replace-regexp-in-string
"\\(\\\\+\\)?\\(,\\)"
(lambda (str)
(let ((len (length (match-string 1 str))))
(if (evenp len) (concat (make-string (/ len 2) ?\\) "\000")
(concat (make-string (/ (1- len) 2) ?\\) ","))))
(org-matcĥ-string-no-properties 3) nil t)
"\000")
That is starting to make sense... :-)
You might want to use the (function (lambda ...)) form.
With the current implementation (and in your refactoring), it is
impossible to have '("a\,b").
Yes, you'd need a second form of quoting to properly support that. It's
also impossible to have leading or trailing whitespace, so I don't know
how important it is to support this edge case of "\,".
If consistency is a matter, a slightly different patch can require to
escape every backslash character. Though, I don't think it is necessary.
I'm not sure it is worth the trouble.
Regards,
--
Achim.
(on the road :-)
Re: [O] [RFC] Org version of the Org manual, Achim Gratz, 2013/03/17
- Re: [O] [RFC] Org version of the Org manual, Nicolas Goaziou, 2013/03/21
- Re: [O] [RFC] Org version of the Org manual, Achim Gratz, 2013/03/22
- Re: [O] [RFC] Org version of the Org manual, Nicolas Goaziou, 2013/03/22
- Re: [O] [RFC] Org version of the Org manual,
Achim Gratz <=
- Re: [O] [RFC] Org version of the Org manual, Nicolas Goaziou, 2013/03/22
- Re: [O] [RFC] Org version of the Org manual, Achim Gratz, 2013/03/23
- Re: [O] [RFC] Org version of the Org manual, Nicolas Goaziou, 2013/03/23