emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* New LaTeX exporter, Invalid search bound
@ 2012-09-22 16:35 Thomas S. Dye
  2012-09-23  8:00 ` Nicolas Goaziou
  0 siblings, 1 reply; 3+ messages in thread
From: Thomas S. Dye @ 2012-09-22 16:35 UTC (permalink / raw)
  To: Org-mode

Aloha all,

A document that exported nicely with the new LaTeX exporter on 9/18 now
fails with a more recent pull from git. I've included a portion of the
backtrace and the section of the org file that triggers the error.

Org-mode version 7.9.1 (release_7.9.1-299-g08c5ea @ /Users/dk/.emacs.d/src/org-mode/lisp/)

Here is the (hopefully) relevant portion of the (really large) backtrace:

Debugger entered--Lisp error: (error "Invalid search bound (wrong side of point)")
  re-search-forward("^\\(?:\\*+ \\|\\[\\(?:[0-9]+\\|fn:[-_[:word:]]+\\)\\]\\|[ 	]*\\(?:$\\|\\(?:|\\|\\+-[-+]\\)\\|[#:]\\|-\\{5,\\}[ 	]*$\\|\\\\begin{\\([A-Za-z0-9]+\\*?\\)}\\|\\(?:\\(?:CLO\\(?:CK\\|SED\\)\\|DEADLINE\\|SCHEDULED\\):\\)\\|\\(?:[-+*]\\|\\(?:[0-9]+\\)[.)]\\)\\(?:[ 	]\\|$\\)\\)\\)" 67425 m)
  org-element-paragraph-parser(67425 (67425 :name "define-biblatex-footcitetext-link"))
  org-element--current-element(67425 nil nil nil)
  org-element--parse-elements(67149 67425 nil nil nil nil (section (:begin 67149 :end 67425 :contents-begin 67149 :contents-end 67425 :post-blank 0)))
  org-element--parse-elements(67149 67425 section nil nil nil (headline (:raw-value "Standard Biblatex citation commands" :begin 67109 :end 67425 :pre-blank 1 :hiddenp outline :contents-begin 67149 :contents-end 67425 :level 2 :priority nil :tags nil :todo-keyword nil :todo-type nil :scheduled nil :deadline nil :timestamp nil :clock nil :post-blank 1 :footnote-section-p nil :archivedp nil :commentedp nil :quotedp nil :category "???" :title ("Standard Biblatex citation commands"))))


Here is the section of the org file that triggers the error:
 
** Standard Biblatex citation commands

#+name: define-standard-biblatex-commands
#+begin_src emacs-lisp :noweb yes :results silent :exports none
  <<define-biblatex-cite-link>>
  <<define-biblatex-cap-cite-link>>
  <<define-biblatex-parencite-link>>
  <<define-biblatex-cap-parencite-link>>
  <<define-biblatex-footcite-link>>
  <<define-biblatex-footcitetext-link>>

#+end_src

#+name: define-biblatex-cite-link
#+begin_src emacs-lisp :results silent :exports none
  (org-add-link-type 
   "cite" 'ebib
   (lambda (path desc format)
     (cond
      ((eq format 'html)
       (format "(<cite>%s</cite>)" path))
      ((eq format 'latex)
       (if (or (not desc) (equal 0 (search "cite:" desc)))
           (format "\\cite{%s}" path)
         (format "\\cite[%s][%s]{%s}"
                 (cadr (split-string desc ";"))
                 (car (split-string desc ";"))  path))))))
#+end_src

#+name: define-biblatex-cap-cite-link
#+begin_src emacs-lisp :results silent :exports none
  (org-add-link-type 
   "Cite" 'ebib
   (lambda (path desc format)
     (cond
      ((eq format 'html)
       (format "(<cite>%s</cite>)" path))
      ((eq format 'latex)
       (if (or (not desc) (equal 0 (search "Cite:" desc)))
           (format "\\Cite{%s}" path)
         (format "\\Cite[%s][%s]{%s}"
                 (cadr (split-string desc ";"))
                 (car (split-string desc ";"))  path))))))
#+end_src

#+name: define-biblatex-parencite-link
#+begin_src emacs-lisp :results silent :exports none
  (org-add-link-type 
   "parencite" 'ebib
   (lambda (path desc format)
     (cond
      ((eq format 'html)
       (format "(<cite>%s</cite>)" path))
      ((eq format 'latex)
       (if (or (not desc) (equal 0 (search "parencite:" desc)))
           (format "\\parencite{%s}" path)
         (format "\\parencite[%s][%s]{%s}"
                 (cadr (split-string desc ";"))
                 (car (split-string desc ";"))  path))))))
#+end_src

#+name: define-biblatex-cap-parencite-link
#+begin_src emacs-lisp :results silent :exports none
  (org-add-link-type 
   "Parencite" 'ebib
   (lambda (path desc format)
     (cond
      ((eq format 'html)
       (format "(<cite>%s</cite>)" path))
      ((eq format 'latex)
       (if (or (not desc) (equal 0 (search "Parencite:" desc)))
           (format "\\Parencite{%s}" path)
         (format "\\Parencite[%s][%s]{%s}"
                 (cadr (split-string desc ";"))
                 (car (split-string desc ";"))  path))))))
#+end_src

#+name: define-biblatex-footcite-link
#+begin_src emacs-lisp :results silent :exports none
  (org-add-link-type 
   "footcite" 'ebib
   (lambda (path desc format)
     (cond
      ((eq format 'html)
       (format "(<cite>%s</cite>)" path))
      ((eq format 'latex)
       (if (or (not desc) (equal 0 (search "footcite:" desc)))
           (format "\\footcite{%s}" path)
         (format "\\footcite[%s][%s]{%s}"
                 (cadr (split-string desc ";"))
                 (car (split-string desc ";"))  path))))))
#+end_src

#+name: define-biblatex-footcitetext-link
#+begin_src emacs-lisp :results silent :exports none
  (org-add-link-type 
   "footcitetext" 'ebib
   (lambda (path desc format)
     (cond
      ((eq format 'html)
       (format "(<cite>%s</cite>)" path))
      ((eq format 'latex)
       (if (or (not desc) (equal 0 (search "footcitetext:" desc)))
           (format "\\footcitetext{%s}" path)
         (format "\\footcitetext[%s][%s]{%s}"
                 (cadr (split-string desc ";"))
                 (car (split-string desc ";"))  path))))))
#+end_src

All the best,
Tom
-- 
Thomas S. Dye
http://www.tsdye.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-09-23 16:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-09-22 16:35 New LaTeX exporter, Invalid search bound Thomas S. Dye
2012-09-23  8:00 ` Nicolas Goaziou
2012-09-23 16:52   ` Thomas S. Dye

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).