Minor bugfix
This commit is contained in:
parent
1863e14b34
commit
37e1b0a6c0
|
@ -76,36 +76,36 @@ local grammar = P{
|
||||||
chunk = V"line"^0 * V"plainline" * V"ending"
|
chunk = V"line"^0 * V"plainline" * V"ending"
|
||||||
}
|
}
|
||||||
|
|
||||||
local text = [[
|
--local text = [[
|
||||||
this is **a big** test with ''italics''!
|
--this is **a big** test with ''italics''!
|
||||||
we need to > sanitize < things that could be tags
|
--we need to > sanitize < things that could be tags
|
||||||
like really <b> badly </b>
|
--like really <b> badly </b>
|
||||||
words can include any'single item without=penalty
|
--words can include any'single item without=penalty
|
||||||
Can you use '''one tag ==within== another tag'''?
|
--Can you use '''one tag ==within== another tag'''?
|
||||||
let's see if [spoiler]spoiler tags work[/spoiler]
|
--let's see if [spoiler]spoiler tags work[/spoiler]
|
||||||
things might even __go over
|
--things might even __go over
|
||||||
multiple lines__ blah
|
--multiple lines__ blah
|
||||||
Let's test out those [code]
|
--Let's test out those [code]
|
||||||
code tag,s and see how well
|
--code tag,s and see how well
|
||||||
they work
|
--they work
|
||||||
here's ome
|
--here's ome
|
||||||
preformated <with injection>
|
--preformated <with injection>
|
||||||
text
|
--text
|
||||||
[/code]
|
--[/code]
|
||||||
> Or have blank lines
|
--> Or have blank lines
|
||||||
|
|
||||||
one important thing is that greentext > should not start in the middle of a line
|
--one important thing is that greentext > should not start in the middle of a line
|
||||||
> this next line is a green text, what if I include **markup** inside it?
|
--> this next line is a green text, what if I include **markup** inside it?
|
||||||
< and after '''it is''' a pinktext
|
--< and after '''it is''' a pinktext
|
||||||
> because of some of these restrictions **bold text
|
--> because of some of these restrictions **bold text
|
||||||
cannot go over multiple lines** in a green text
|
--cannot go over multiple lines** in a green text
|
||||||
__and finally__ there might be some text with '''
|
--__and finally__ there might be some text with '''
|
||||||
incomplete syntax <b> with injection</b> !!!!
|
--incomplete syntax <b> with injection</b> !!!!
|
||||||
]]
|
--]]
|
||||||
|
|
||||||
--return function(text)
|
return function(text)
|
||||||
--return table.concat({grammar:match(text .. "\n")}," ")
|
return table.concat({grammar:match(text .. "\n")}," ")
|
||||||
--end
|
|
||||||
for k,v in pairs({grammar:match(text)}) do
|
|
||||||
print(k,":",v)
|
|
||||||
end
|
end
|
||||||
|
--for k,v in pairs({grammar:match(text)}) do
|
||||||
|
--print(k,":",v)
|
||||||
|
--end
|
||||||
|
|
Loading…
Reference in New Issue