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

If statements and boolean operators #16

Merged
merged 6 commits into from
Aug 26, 2024
Merged

If statements and boolean operators #16

merged 6 commits into from
Aug 26, 2024

Conversation

dwightguth
Copy link
Contributor

Adds:

  • If statements
  • && and ||
  • Blocks

@dwightguth dwightguth marked this pull request as ready for review August 26, 2024 16:25
if (x) {
} else {
require(false, "");
}
Copy link
Contributor

Choose a reason for hiding this comment

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

My only comment is that when the if condition is false, both the if then and the full if then else are tested. Here, when the if condition is true, only the if then else case is tested. You may consider adding a check for the if then case.

@dwightguth dwightguth merged commit 5585171 into main Aug 26, 2024
1 check passed
@dwightguth dwightguth deleted the if branch August 26, 2024 16:46
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