/**
* Extracts non scalar types from a field doc comment and creates a
* matching type instance.
*
* @return \PDepend\Source\AST\ASTClassOrInterfaceReference
* @since 0.9.6
*/
private function parseFieldDeclarationClassOrInterfaceReference()
{
$annotations = $this->parseVarAnnotation($this->docComment);
foreach ($annotations as $annotation) {
if (Type::isScalarType($annotation) === false) {
return $this->builder->buildAstClassOrInterfaceReference($annotation);
}
}
return null;
}