Add aliases for Context class because newer phpunit versions have a global Context class

This commit is contained in:
Mike van Riel
2016-02-26 21:44:16 +01:00
parent 332c96dab8
commit 52723f0fb8
22 changed files with 65 additions and 68 deletions
+5 -5
View File
@@ -12,7 +12,7 @@
namespace phpDocumentor\Reflection\DocBlock;
use phpDocumentor\Reflection\Types\Context;
use phpDocumentor\Reflection\Types\Context as TypeContext;
/**
* Creates a new Description object given a body of text.
@@ -50,11 +50,11 @@ class DescriptionFactory
* Returns the parsed text of this description.
*
* @param string $contents
* @param Context $context
* @param TypeContext $context
*
* @return Description
*/
public function create($contents, Context $context = null)
public function create($contents, TypeContext $context = null)
{
list($text, $tags) = $this->parse($this->lex($contents), $context);
@@ -112,11 +112,11 @@ class DescriptionFactory
* Parses the stream of tokens in to a new set of tokens containing Tags.
*
* @param string[] $tokens
* @param Context $context
* @param TypeContext $context
*
* @return string[]|Tag[]
*/
private function parse($tokens, Context $context)
private function parse($tokens, TypeContext $context)
{
$count = count($tokens);
$tagCount = 0;