intersystems / intersystems/isc-codetidy

Detect likely-unintended IF statements with multiple clauses, no parentheses

Open
#42 0 comments 0 reactions 1 assignee Claimed by @isc-egabhart View on GitHub
enhancement
Dominant language
ObjectScript
Stars
4
Forks
6
PR merge metrics
No merged PRs in 30d

Description

Reported internally within InterSystems:

It's a relatively common error to not include parenthesis in IF statements with multiple clauses. This almost always produces unexpected results.

I'd suggest two basic warnings:

|| - Any use of || where adjacent non-whitespace characters are not the appropriate parenthesis.
&& - Any use of && where adjacent non-whitespace characters are not the appropriate parenthesis.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.