emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <n.goaziou@gmail.com>
To: Jonathan Leech-Pepin <jonathan.leechpepin@gmail.com>
Cc: Org Mode Mailing List <emacs-orgmode@gnu.org>
Subject: Re: Bug? : Nested macro expansion
Date: Thu, 06 Dec 2012 22:47:32 +0100	[thread overview]
Message-ID: <8738ziua2z.fsf@gmail.com> (raw)
In-Reply-To: <CAEWDx5eCd3mh3H0cNm7cUjPaj2L5wG9nUvYgj8XKFcXpOv5O1A@mail.gmail.com> (Jonathan Leech-Pepin's message of "Thu, 6 Dec 2012 15:48:48 -0500")

Hello,

Jonathan Leech-Pepin <jonathan.leechpepin@gmail.com> writes:

> When trying to insert a macro as one of the variables in another macro
> (inline and not in the definition), the export fails in both exporters
> in different ways.
>
> Using the following example:
>
> #+begin_src org
> #+MACRO: test2 /$1/
> #+MACRO: test3 *$1*
> #+MACRO: test {{{test2($1)}}} - $2
> #+MACRO: test4 $1 - $2
>
> Test
> 1. {{{test(hello,goodbye)}}}
> 2. {{{test(hello, {{{test3(goodbye)}}})}}}
> 3. {{{test({{{test3(hello)}}},goodbye)}}}
> 4. {{{test4({{{test3(hello)}}},goodbye)}}}
> 5. {{{test4(hello,{{{test3(goodbye)}}})}}}
> #+end_src

You're not supposed to nest macro calls. Only macro definitions.


Regards,

-- 
Nicolas Goaziou

      reply	other threads:[~2012-12-06 21:51 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-06 20:48 Bug? : Nested macro expansion Jonathan Leech-Pepin
2012-12-06 21:47 ` Nicolas Goaziou [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8738ziua2z.fsf@gmail.com \
    --to=n.goaziou@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=jonathan.leechpepin@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).