You can disable a rule before or after you run a code review.
If you disable the rule before you run the review, the rule will not
be applied to the code base. Consequently, no findings for the rule are produced.
If you disable the rule after you run the review, the finding gets marked
with an X. Visually, this helps you distinguish between enabled findings that
you want to evaluate and disabled ones that you do not want to examine at
this time.
To disable a rule before or after running a code review:
- To disable a rule before running a code review, on the toolbar
in the Code Review view click the Manage Rules icon,
and perform the following
tasks:- In the Select Code Review list, click the code review you want
to run.
- Expand the category that contains the rule you want to disable.
- Clear the check box of any rule that you do not want applied when
you run the selected code review.
- Click OK to accept the rules you excluded from
the code review.
- To disable a rule after running a code review, right-click the
finding in the Code Review view and choose one of the
following actions:
- Click Disable rule on the pop-up menu to disable
the rule in only the finding you selected. In the findings list, an X appears
next to the selected finding.
- Click Disable rule on filename to
disable the rule in the entire file. In the findings list, an X appears
next to each finding in that file that did not adhere to the rule.
To enable a disabled rule before you run a code review, click the
disabled rule. To enable a disabled rule after you run a code review, right-click
the finding and click Enable rule or Enable
rule filename.