[GRASS-QA] GRASS QA: martinl |select.c snap.c | 1 clones | 0 monsters |0 warnings

soccerlab.info at gmail.com soccerlab.info at gmail.com
Sat Mar 7 20:17:58 EST 2009


Hello martinl,

here's a report on your recent GRASS-SVN change : 

ANALYSIS 

your changes to files/class/methods/functions : 

*****************************************************************
          File :grass/trunk/lib/vector/vedit/select.c
*****************************************************************

          Function
Vedit_select_by_query(Begins at: 43, Ends at:125)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      16 |       |           OK |        16 |
ParamNBR:     |       6 |       |           OK |         6 |
CalledNBR:    |      21 |       |           OK |        21 |
LOC:          |      83 |       |           OK |        83 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a            OK           |
-----------------------------------------------------------+
metrics are OK


merge_lists(Begins at: 247, Ends at:265)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       3 |    ** | BABY-MONSTER |         3 |
ParamNBR:     |       2 |    ** | BABY-MONSTER |         2 |
CalledNBR:    |       5 |    ** | BABY-MONSTER |         5 |
LOC:          |      19 |    ** | BABY-MONSTER |        19 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


select_by_query(Begins at: 134, Ends at:237)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      18 |    ** | BABY-MONSTER |        18 |
ParamNBR:     |       7 |    ** | BABY-MONSTER |         7 |
CalledNBR:    |      23 |     * |      WARNING |        23 |
LOC:          |     104 |     * |      WARNING |       104 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Clone analysis:
This file has 1 potentially cloned functions:


In /var/project-manager/grass/grassSVN/grass/trunk/lib/vector/vedit/select.c clones of merge_lists are:
          /var/project-manager/grass/grassSVN/grass/trunk/vector/v.edit/select.c  merge_lists

*****************************************************************
          File :grass/trunk/lib/vector/vedit/snap.c
*****************************************************************

          Function
Vedit_snap_line(Begins at: 102, Ends at:163)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       8 |     * |      WARNING |         8 |
ParamNBR:     |       7 |    ** | BABY-MONSTER |         7 |
CalledNBR:    |       8 |       |           OK |         8 |
LOC:          |      62 |     * |      WARNING |        62 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Vedit_snap_lines(Begins at: 178, Ends at:213)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       5 |       |           OK |         5 |
ParamNBR:     |       6 |    ** | BABY-MONSTER |         6 |
CalledNBR:    |       7 |       |           OK |         7 |
LOC:          |      36 |       |           OK |        36 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Vedit_snap_point(Begins at: 31, Ends at:85)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       8 |     * |      WARNING |         8 |
ParamNBR:     |       7 |    ** | BABY-MONSTER |         7 |
CalledNBR:    |       8 |       |           OK |         8 |
LOC:          |      55 |     * |      WARNING |        55 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Clone analysis:
This file does not contain cloned functions

____________________________________________


Threshold grass key metrics values at Sat Mar 07 20:24:02 EST 2009 are:
----------------------+-----------+-----------+-----------+
                      | warning   | middle    | extrem    |
                      | limits    | limits    | limits    |
----------------------+-----------+-----------+-----------+
Complexity (Cyclo):   |         6 |        13 |        21 |
ParamNBR:             |         3 |         6 |         9 |
CalledNBR:            |        10 |        23 |        37 |
LOC:                  |        42 |        91 |       141 |
----------------------+-----------+-----------+-----------+



Measures (see below Web page for details) :
    -Complexity (Cyclo): a complexity index 
    -ParamNBR: number of passed parameters 
    -CalledNBR: number of called functions 
    -LOC: Lines Of Code 
    -Global analysis: based on 21 metrics(the fourth preceding include)

Message interpretation :
    OK : Nothing to say at all
    *  : this is getting close to be out of range, consider revising the code
    ** : this is a baby monster, you should revise this function
    ***: this is a monster, definitely you should revise this function

Conclusion interpretation :
    CORRECT     : if all metrics are situated before warning limits
    WARNING     : if 1 to more metrics are between warning and middle limits
    BABY_MONSTER: if 1 to more metrics are between middle and extreme limits
    MONSTERS    : if 1 to more metrics are in the extreme limits


_______________________________________________
Brought to you by :
	SOftware Cost-effective Change and Evolution Research (SOCCER) laboratory 

Please visite our web site on your project at :
    http://web.soccerlab.polymtl.ca/project-manager/grass-website/index.html


More information about the grass-qa mailing list