Skip to content
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

Make it easier to syntactically wrap another combinator. #49

Closed
robrix opened this issue Jan 8, 2015 · 6 comments
Closed

Make it easier to syntactically wrap another combinator. #49

robrix opened this issue Jan 8, 2015 · 6 comments

Comments

@robrix
Copy link
Owner

robrix commented Jan 8, 2015

For example parenthesized expressions. The parens are syntactically important but don’t contribute to the tree; the wrapped combinator’s result should therefore be passed through, and the wrapping terms should be dropped.

@robrix
Copy link
Owner Author

robrix commented Jan 8, 2015

Equivalent to ignore(opening) ++ body ++ ignore(closing) I suppose.

@neilpa
Copy link
Contributor

neilpa commented Apr 5, 2015

I didn't realize this equivalence and wrote a custom bookend operator. Although it was slightly different since it assumed body* which it then flattened the elements for.

@robrix
Copy link
Owner Author

robrix commented Apr 5, 2015

bookend is a nice name for this!

@neilpa
Copy link
Contributor

neilpa commented Apr 5, 2015

I probably spent far too much time thinking about it after iterating through wrap, quote, etc.

@bencochran
Copy link
Collaborator

Is this still necessary given #91? (namely opening *> body <* closing being now possible)

@robrix
Copy link
Owner Author

robrix commented Nov 12, 2015

Probably not; closing.

@robrix robrix closed this as completed Nov 12, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants