1
0
Fork 0

Add comment on try/catch in DefinitionResolver

pull/357/head
Rob Lourens 2017-06-06 14:39:44 -07:00
parent e0a7b2108e
commit 65363b7390
1 changed files with 2 additions and 0 deletions

View File

@ -151,6 +151,8 @@ class DefinitionResolver
$context = new Types\Context($namespaceName, $namespaceImportTable); $context = new Types\Context($namespaceName, $namespaceImportTable);
try { try {
// create() throws when it thinks the doc comment has invalid fields.
// For example, a @see tag that is followed by something that doesn't look like a valid fqsen will throw.
return $this->docBlockFactory->create($docCommentText, $context); return $this->docBlockFactory->create($docCommentText, $context);
} catch (\InvalidArgumentException $e) { } catch (\InvalidArgumentException $e) {
return null; return null;