wikiotics/creoleparser

Macros work on only a single paragraph

GoogleCodeExporter opened this issue · 4 comments

What steps will reproduce the problem?
1. Make a piece of text with either a macro <<mymacro>>blah<</mymacro>> 
where the innards have two repeated '\n's, e.g.

<<code>>
Hey
there

big
guy
<</code>>
2. Try to parse this through creoleparser
3. Realize that it doesn't see the macro as having a body.

What is the expected output? What do you see instead?
I expect that the entire middle between the macro beginning and end is fed 
in as the body, but only the beginning tag is and it acts as if it has no 
body.

What version of the product are you using? On what operating system?
CreoleParser 0.6.0, using creole11_base. Python 2.5 on Mac OS X 10.5 and 
Ubuntu Linux.

Please provide any additional information below.
This also occurs for pre statements, e.g.
{{{
Hey
there

big
guy
}}}

Original issue reported on code.google.com by montysty...@gmail.com on 2 Apr 2009 at 10:13

Hi,

I am not able to reproduce this and I am not able to test on a Mac (although I 
can't 
see this making a difference). Please try this first for a sanity check:

>>> from creoleparser import Parser, creole11_base, create_dialect
>>> parse = Parser(create_dialect(creole11_base))
>>> parse("{{{\nHello\n\nWorld\n}}}")
'<pre>Hello\n\nWorld\n</pre>\n'

If this works as expected, please send a full code example and I'll try again 
to 
reproduce.

Steve

Original comment by stephen....@gmail.com on 2 Apr 2009 at 10:51

  • Changed state: Started
Note that macros only span paragraphs if a special syntax is used:

http://creoleparser.googlecode.com/svn/docs/syntax.html#macros

Original comment by stephen....@gmail.com on 2 Apr 2009 at 11:29

Sorry, you're completely right. This is not a bug, I was entering it in wrong.

Original comment by montysty...@gmail.com on 3 Apr 2009 at 6:18

Thanks for letting me know :)

Original comment by stephen....@gmail.com on 3 Apr 2009 at 6:48

  • Changed state: Invalid