-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Significant indentation #54
Conversation
0000000
to
5e89f27
Compare
@jspahrsummers Note that the actual parsing is functioning just fine—the remainder of the work to be done on this branch is documentation/explanatory. We can point Carthage/ogdl-swift#1 at this branch, or we can just define |
@@ -224,6 +236,13 @@ infix operator --> { | |||
prefix operator % {} | |||
|
|||
|
|||
/// Bind operator. | |||
infix operator >>= { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was this going to become >>-
, per @gfontenot's tweets?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, note to-do item at top.
I think I'd prefer to target this branch, just to minimize code duplication. |
👍 |
`>>=` already has defined semantics as an assignment operator, & `>>-` has been standardized(ish) by Runes & swiftz.
This matches Runes.
It’s not actually doing any significant indentation handling or showing how >>- is used, so might as well rename it.
Defines >>= over parsers, and demonstrates the use of it for parsing structurally significant indentation, in this case a rose tree of list items.
Documentation for structurally significant indentation parsing.Should there be direct conveniences in support of parsing structurally significant indentation?>>-
instead of>>=
(a la Runes and swiftz)Fixes #42.
Fixes #50.
/cc @jspahrsummers because of the relevance to Carthage/ogdl-swift#1
/cc @mdiep because of the relevance to Markdown parsing
If this isn’t madness, I don’t know what is.