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

Implement %%, %%=, and operator"" #371

Merged
merged 2 commits into from
Oct 8, 2023

Conversation

LemonInTheDark
Copy link
Contributor

@LemonInTheDark LemonInTheDark commented Oct 5, 2023

The float stuff was easy. Operator was too, just took a bit to realize how it worked

Nothin much else to say, outside that I needed to roll my own operation for this one, since float remainder is kinda hard to find (and I couldn't after cursory reading)

The float stuff was easy. Operator was too, just took a bit to realize
how it worked
Nothin much else to say, outside that I needed to roll my own operation
for this one, since float remainder is kinda hard to find (and I
couldn't after cursory reading)
@LemonInTheDark LemonInTheDark changed the title Adds support for %% and its derivatives Adds support for %% and its derivatives (Also operator""()) Oct 5, 2023
@@ -944,6 +950,8 @@ impl<'ctx, 'an, 'inp> Parser<'ctx, 'an, 'inp> {
} else {
last_part.push_str("[]");
}
} else if self.exact(Punct(EmptyQuote))?.is_some() {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A less shocking change might be to look for an empty Token::String here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

handled, I think?

crates/dreammaker/src/lexer.rs Outdated Show resolved Hide resolved
@SpaceManiac SpaceManiac changed the title Adds support for %% and its derivatives (Also operator""()) Add support for %%, %%=, and operator"" Oct 8, 2023
@SpaceManiac SpaceManiac changed the title Add support for %%, %%=, and operator"" Implement %%, %%=, and operator"" Oct 8, 2023
@SpaceManiac SpaceManiac merged commit 47ef0c5 into SpaceManiac:master Oct 8, 2023
@SpaceManiac SpaceManiac added this to the suite v1.8 milestone Nov 19, 2023
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.

2 participants