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

#427 Lazy operands for short-circuit evaluation of logic operators #432

Merged
merged 4 commits into from
Jan 16, 2024

Conversation

stevenylai
Copy link
Contributor

@stevenylai stevenylai commented Jan 16, 2024

This implementation changes existing && and || operators and it seems to be fine. Alternatively we can keep the existing operators unchanged but then we need to add tests for using custom operators. I can see currently all features such as isLazy from functionParameter are used at least once by one of the built-in operator/function so I last time I checked, I didn't find tests for implementing some features purely for the purpose of being used by custom operator/function.

This fixes: #427

Copy link

sonarcloud bot commented Jan 16, 2024

Quality Gate Passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@uklimaschewski uklimaschewski merged commit ad4ad69 into ezylang:main Jan 16, 2024
2 checks passed
@uklimaschewski
Copy link
Collaborator

Thank you very much!

@stevenylai stevenylai deleted the lazy-operands branch January 17, 2024 12:00
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.

With introduction of null, it's better to allow short circuiting (lazy evaluation) for those boolean operators
2 participants