From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rasmus Subject: [bug?] org-inside-latex-fragment-p broken? Date: Fri, 23 Jun 2017 12:26:36 +0200 Message-ID: <87o9tfngo3.fsf@pank.eu> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:58850) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dOLnc-0004Lk-An for emacs-orgmode@gnu.org; Fri, 23 Jun 2017 06:26:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dOLnZ-0007PA-46 for emacs-orgmode@gnu.org; Fri, 23 Jun 2017 06:26:48 -0400 Received: from [195.159.176.226] (port=46028 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dOLnY-0007OG-RE for emacs-orgmode@gnu.org; Fri, 23 Jun 2017 06:26:45 -0400 Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1dOLnR-0006ql-B6 for emacs-orgmode@gnu.org; Fri, 23 Jun 2017 12:26:37 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode@gnu.org Hi, org-inside-LaTeX-fragment-p seems to assume that a latex-fragment only exists beyond the first paragraph. It does fails to predict the fragment in this simple file #+begin_src org foo $x$ bar test `org-inside-LaTeX-fragment-p' on the "$x$" above. #+end_src It seems to be fixed if we replace, (lim (progn (re-search-backward (concat "^\\(" paragraph-start "\\)") nil t) (point))) With (lim (save-excursion (backward-paragraph) (point))) Should I push this? Thanks, Rasmus -- You people at the NSA are becoming my new best friends!