Is there way to report SLOCs for functions?

Options

I was looking for a rule similar to "Report Cyclomatic Complexity [METRICS-29-5]", but for LOCs. Is there such a rule or some other way to report LOCs for the functions?

Answers

  • mstaron
    mstaron Posts: 35 ✭
    Options

    You can use Metrics Analysis. It contains metrics like Source Lines in Methods [METRIC.NOSLIM] or Logical Lines in Methods [METRIC.NOLLOCIM] (I'm not sure which one is better for you). You should use the 'Metrics' configuration to enable these metrics.

  • george_vlasov
    Options

    Sounds good! Could you point me to the manual document that describes Metrics Analysis? I searched in the "c++test_96_rules.pdf" file and could not find any references.

  • mstaron
    mstaron Posts: 35 ✭
    Options

    Which C++test version do you use? I'm not sure if Metrics Analysis is available in this version.

  • Andrey Madan
    Andrey Madan Posts: 388 ✭✭✭
    Options

    @george_vlasov - please ping me and we can talk about it.