You are here

function do_coder_review_grep_invert in Coder 6

Same name and namespace in other branches
  1. 5.2 coder.module \do_coder_review_grep_invert()
  2. 5 coder.module \do_coder_review_grep_invert()
  3. 6.2 coder.module \do_coder_review_grep_invert()
  4. 7.2 coder_review/coder_review.common.inc \do_coder_review_grep_invert()
  5. 7 coder_review/coder_review.module \do_coder_review_grep_invert()

Search for potentially missing string.

@note See do_coder_review_regex() for arguments.

1 call to do_coder_review_grep_invert()
do_coder_review in ./coder.module
Perform code review for a review array.

File

./coder.module, line 1547
Developer Module that assists with code review and version upgrade that supports a plug-in extensible hook system so contributed modules can define additional review standards.

Code

function do_coder_review_grep_invert(&$coder_args, $review, $rule, $lines, &$results) {
  if (isset($rule['#value'])) {
    foreach ($lines as $lineno => $line) {
      if (_coder_search_string($line, $rule)) {
        return;
      }
    }
    $severity_name = _coder_severity_name($coder_args, $review, $rule);
    _coder_error($results, $rule, $severity_name);
  }
}