Permalink
Browse files

Merge pull request #404 from chuckhoupt/argwarn-fix

Correct handling of warnOnMissingMethodArgument to suppress missing, rather then unknown warning.
  • Loading branch information...
2 parents 6f0df51 + d582469 commit 2e6c541b9e9ea24ac86071daf0148113223ef375 @tomaz committed Sep 29, 2013
Showing with 2 additions and 2 deletions.
  1. +2 −2 Processing/GBProcessor.m
View
@@ -226,7 +226,7 @@ - (void)processParametersFromComment:(GBComment *)comment matchingMethod:(GBMeth
[names enumerateObjectsUsingBlock:^(NSString *name, NSUInteger idx, BOOL *stop) {
GBCommentArgument *parameter = [parameters objectForKey:name];
if (!parameter) {
- if (method.includeInOutput)
+ if (self.settings.warnOnMissingMethodArgument && method.includeInOutput)
GBLogXWarn(comment.sourceInfo, @"%@: Description for parameter '%@' missing for %@!", comment.sourceInfo, name, method);
return;
}
@@ -240,7 +240,7 @@ - (void)processParametersFromComment:(GBComment *)comment matchingMethod:(GBMeth
[description appendString:parameter.argumentName];
[sorted addObject:parameter];
}];
- if (self.settings.warnOnMissingMethodArgument && method.includeInOutput) GBLogXWarn(comment.sourceInfo, @"%@: %ld unknown parameter descriptions (%@) found for %@", comment.sourceInfo, [parameters count], description, method);
+ if (method.includeInOutput) GBLogXWarn(comment.sourceInfo, @"%@: %ld unknown parameter descriptions (%@) found for %@", comment.sourceInfo, [parameters count], description, method);
}
// Finaly re-register parameters to the comment if necessary (no need if there's only one parameter).

0 comments on commit 2e6c541

Please sign in to comment.