From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Galen Menzel" Subject: Source blocks confused by Org syntax Date: Thu, 14 Feb 2019 12:14:36 -0800 Message-ID: <713BB3F4-0E39-4C67-B76E-18826CE39D3F@utexas.edu> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="=_MailMate_06E9F88A-3352-4B91-82F2-F883D6BAB5DF_=" Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([209.51.188.92]:41491) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1guNPR-0006Dl-Cx for emacs-orgmode@gnu.org; Thu, 14 Feb 2019 15:15:02 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1guNPQ-0000CL-5Q for emacs-orgmode@gnu.org; Thu, 14 Feb 2019 15:15:01 -0500 Received: from mail-pf1-x430.google.com ([2607:f8b0:4864:20::430]:44024) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1guNPP-0008Pi-JJ for emacs-orgmode@gnu.org; Thu, 14 Feb 2019 15:15:00 -0500 Received: by mail-pf1-x430.google.com with SMTP id q17so3631587pfh.10 for ; Thu, 14 Feb 2019 12:14:40 -0800 (PST) Received: from [192.168.1.3] (c-73-170-177-190.hsd1.ca.comcast.net. [73.170.177.190]) by smtp.gmail.com with ESMTPSA id e63sm9063712pfc.47.2019.02.14.12.14.37 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 14 Feb 2019 12:14:37 -0800 (PST) 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: Org Mode List --=_MailMate_06E9F88A-3352-4B91-82F2-F883D6BAB5DF_= Content-Type: text/plain; charset=utf-8; format=flowed; markup=markdown Content-Transfer-Encoding: 8bit Hi all, I’m finding that org source blocks are getting confused if their text contains org syntax. For example, in the text below, org considers all the lines beginning with asterisks in the text below to be org headers, and will fold them accordingly: ``` #+BEGIN_SRC text This source block folds just fine #+END_SRC #+BEGIN_SRC text This source block doesn't fold properly because it contains an org headline * See? #+END_SRC #+BEGIN_SRC emacs-lisp (surely this problem doesnt apply in emacs-lisp mode) * Does it? ** Sadly it does #+END_SRC #+BEGIN_QUOTE The problem also pertains to quotes * as you can see #+END_QUOTE #+BEGIN_EXAMPLE And examples are no exception * As you can see again #+END_EXAMPLE ``` Since all these “headlines” occur inside source, quote, or example blocks, they shouldn’t be considered org headlines. In addition, the blocks that contain lines beginning with asterisks won’t fold properly. I’m seeing this behavior in both 9.2.1 and 9.1.9. Are others seeing this? Please let me know if I can provide any further information! Best, Galen --=_MailMate_06E9F88A-3352-4B91-82F2-F883D6BAB5DF_= Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable

Hi all,

I=E2=80=99m finding that org source blocks are getting co= nfused if their text contains org syntax. For example, in the text below,= org considers all the lines beginning with asterisks in the text below t= o be org headers, and will fold them accordingly:

#+BEGIN_SRC text
This source block folds just fine
#+END_SRC

#+BEGIN_SRC text
This source block doesn't fold properly because it contains an org headli=
ne
* See?
#+END_SRC

#+BEGIN_SRC emacs-lisp
(surely this problem doesnt apply in emacs-lisp mode)
* Does it?
** Sadly it does
 #+END_SRC

 #+BEGIN_QUOTE
 The problem also pertains to quotes
* as you can see
#+END_QUOTE

#+BEGIN_EXAMPLE
And examples are no exception
* As you can see again
#+END_EXAMPLE

Since all these =E2=80=9Cheadlines=E2=80=9D occur inside = source, quote, or example blocks, they shouldn=E2=80=99t be considered or= g headlines. In addition, the blocks that contain lines beginning with as= terisks won=E2=80=99t fold properly.

I=E2=80=99m seeing this behavior in both 9.2.1 and 9.1.9.= Are others seeing this? Please let me know if I can provide any further = information!

Best,

Galen

--=_MailMate_06E9F88A-3352-4B91-82F2-F883D6BAB5DF_=--