-
Notifications
You must be signed in to change notification settings - Fork 113
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
Too few operators recognised for Halstead calculations #160
Comments
I agree that most of these should be recognized. Halstead even refers to the "assignment operator" a few times in The Elements of Software Science, using it to compute some ideal metrics like potential volume. Some of these seem simple to add. A quick glance at the |
It is appreciated that one of Halstead's weaknesses is a lack of agreement on what is and isn't an operator. However, the stats look very kind at the moment, suggesting operators are being missed. It would be good to a have a declaration of operators that are recognised on the docs page.
It seems at the moment detected operators (you are welcome to correct me if I'm wrong) are:
And these are not recognised:
if var:
var would be ignore as an operand, and if does not count as an operatorIMHO these should all impact the Halstead calculations - but I'm guessing its difficult to get the info from the "ast" module?
The text was updated successfully, but these errors were encountered: