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

fix: parenthesis now appear in printed quote objects #143

Merged
merged 3 commits into from
Jul 7, 2024
Merged

Conversation

dgkf
Copy link
Owner

@dgkf dgkf commented Jul 7, 2024

This one ended up exposing a few other bugs related to handling of parenthesis.

Before they weren't actually part of the syntax tree. They just existed through the structure of the tree itself - implicit to the interpreter but non-obvious when printed. Anything that looked like it printed reasonably before was just little tricks I had shoved in to make it look reasonable along the way.

Now parenthesis have their own symbol so this should be much more rigorously handled in the future.

I also spent a little time cleaning up substitute(), which does some "automatic" parentheses insertion when operator precedence might affect behaviors, similar to R.

@dgkf dgkf merged commit ab19c2e into main Jul 7, 2024
11 checks passed
@dgkf dgkf deleted the 140-quote-print branch July 7, 2024 23:58
@dgkf dgkf mentioned this pull request Jul 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant