cvs: phpdoc /scripts check-references.php
| From: | Jakub Vrana | Date: | Tue, 13 Jan 2009 12:47:40 +0000 |
| Subject: | cvs: phpdoc /scripts check-references.php | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-3028@lists.php.net to get a copy of this message | ||
vrana Tue Jan 13 12:47:40 2009 UTC
Modified files:
/phpdoc/scripts check-references.php
Log:
Check only optional parameters
http://cvs.php.net/viewvc.cgi/phpdoc/scripts/check-references.php?r1=1.32&r2=1.33&diff_format=u
Index: phpdoc/scripts/check-references.php
diff -u phpdoc/scripts/check-references.php:1.32 phpdoc/scripts/check-references.php:1.33
--- phpdoc/scripts/check-references.php:1.32 Mon Jan 12 15:52:37 2009
+++ phpdoc/scripts/check-references.php Tue Jan 13 12:47:40 2009
@@ -445,7 +445,7 @@
if ($param == "bool" && strlen($init_source)) {
$init_source = ($init_source ? "true" : "false");
}
- if ($matches[4][$i] != $init_source && (is_int($source_refs[$function_name][0]) ?
$source_refs[$function_name][0] > $i+1 : !in_array($i+1, (array)
$source_refs[$function_name][0]))) {
+ if (($optional_source || $optional_doc) && $matches[4][$i] != $init_source &&
(is_int($source_refs[$function_name][0]) ? $source_refs[$function_name][0] > $i+1 :
!in_array($i+1, (array) $source_refs[$function_name][0]))) {
$error .= "Parameter #" . ($i+1) . " has wrong initial value (" .
$matches[4][$i] . " instead of $init_source) in $filename on line " . ($lineno + $i + 1) .
".\n";
}
}