best static analysis rule for arithmetic complexity?

ajcurtisajcurtis Posts: 11


I have found a few metrics that appear to address operator complexity. Halstead is the metric you find online. It looks like C++test supports several different Halstead complexity calculations but; a. they are not all enabled b. the ones that are enabled are not setup for violation detection. I also found VOCF which can be used for violation detection. It isn't clear if this is different from Halstead. It is also difficult to customize the threshold value.

Looking forward to hearing you methodology.



  • mstaronmstaron Posts: 26

    Metrics analysis results are available on DTP server (there are some Halstead metrics). Each metric uses a different value calculation (described in documentation for every metric). It is possible to set lower and upper thresholds for metrics. See documentation for metrics (Usage->Metrics Calculation). The value of VOCF is checked in rule METRICS-39 and its threshold value can be changed in RuleWizard.

  • ajcurtisajcurtis Posts: 11

    The threshold for rule METRICS-39 can not be changed in the RuleWizard. I have been able to modify the threshold for other METRICS but not this one.

Sign In or Register to comment.