emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug Re: Greater than, less than bug in emacs-lisp source block


From: John Kitchin
Subject: Re: Bug Re: Greater than, less than bug in emacs-lisp source block
Date: Fri, 3 Sep 2021 08:00:01 -0400

That is probably a matter of opinion.

If you use angle brackets as delimiters, e.g. in html, xml in src-blocks, then the current syntax definition makes sense because you can use them to find open and closing brackets, navigate them, etc.. If you don't use those, it makes less sense, and maybe isn't even something you want. 

John

-----------------------------------
Professor John Kitchin (he/him/his)
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803


On Fri, Sep 3, 2021 at 7:42 AM Charles Millar <millarc@verizon.net> wrote:
Thank you, John.

I will give it a try.

However, is this a bug that should be fixed within org source code?

Charlie Millar


On 9/2/21 2:24 PM, John Kitchin wrote:
> I think this issue is described in
> https://emacs.stackexchange.com/questions/50216/org-mode-code-block-parentheses-mismatch.
> There are also some solutions there.
>
>
> John
>
> -----------------------------------
> Professor John Kitchin (he/him/his)
> Doherty Hall A207F
> Department of Chemical Engineering
> Carnegie Mellon University
> Pittsburgh, PA 15213
> 412-268-7803
> @johnkitchin
> http://kitchingroup.cheme.cmu.edu
>
>
>
> On Thu, Sep 2, 2021 at 2:10 PM Charles Millar <millarc@verizon.net> wrote:
>
>> Set up:
>> GNU Emacs 28.0.50 (build 344, x86_64-pc-linux-gnu, GTK+ Version 3.24.23,
>> cairo version 1.16.0) of 2020-12-31
>> Org mode version 9.4.6 (release_9.4.6-637-gd70f28 @
>> /usr/local/share/org-mode/lisp/)
>>
>> The following code will evaluate
>>
>> #+begin_src emacs-lisp
>> (defun Foo ()
>> (if (= 2 4) bar))
>> #+end_src
>>
>> #+RESULTS:
>> : Foo
>> and the opening and closing parentheses match.
>>
>> If a greater than is inserted instead of equals, thus
>>
>> #+begin_src emacs-lisp
>> (defun Foo ()
>> (if (> 2 4) bar))
>> #+end_src
>>
>> it apparently evaluates, however, the closing parenthesis immediately
>> following the "4" is paired with the opening paren before "if" and not
>> the opening paren immediately before the ">"
>>
>> A "less than" results with stranger parenthesis matching - the closing
>> paren after the "4" matches no others; the closing paren immediately
>> after "bar" matches the opening paren before "if"
>>
>> Charlie Millar
>>
>>
>>
>>
>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]