Damn, I lost a cople of "[" somewhere in pasting to the email.
Here the whole thing again.
Brett.
REBOL [
Author: "Brett Handley"
Purpose: "A parse example for Chris."
]
heading-rule: [
(level: 0)
any [ "^-" (level: add level 1)]
["+" | "-"]
opt " "
copy heading [to "^/" | to end]
(append result-block reduce ['heading level heading])
]
match-content-character: complement charset "^-^/"
content-line-rule: [
copy content
some
match-content-character
(append result-block reduce ['content content])
]
simple-format-text: [
(result-block: copy [])
some [
newline | heading-rule | content-line-rule
]
]