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 toString of TypePatternElement #5136

Conversation

TPGamesNL
Copy link
Member

@TPGamesNL TPGamesNL commented Oct 2, 2022

Description

Fixes the toString of TypePatternElement, was a small mistake:
image
If the type doesn't take expressions ((flagMask & SkriptParser.PARSE_EXPRESSIONS) == 0), it means we need to add a *, not a ~. The code had it switched. For types without flags, it'd have added both, if not for the check right before checking if it's not the default flags.

Btw, this change will likely not impact anything at all, because it's just the toString of a pattern, which isn't used in Skript and I doubt it's used in addons


Target Minecraft Versions:
Requirements:
Related Issues:

@TPGamesNL TPGamesNL added the enhancement Feature request, an issue about something that could be improved, or a PR improving something. label Oct 2, 2022
@APickledWalrus APickledWalrus merged commit eea0e1a into SkriptLang:master Oct 6, 2022
@TPGamesNL TPGamesNL deleted the fix/type-pattern-element-to-string-flag branch October 10, 2022 18:47
TheLimeGlass pushed a commit that referenced this pull request Oct 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Feature request, an issue about something that could be improved, or a PR improving something.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants