Feature request from mc388, posted on GitHub Mar 14, 2016
@return \Magento\Sales\Api\Data\OrderInterface Order interface
@return OrderInterface Order interface
Class OrderInterface does not exists
I think the issue is in Magento\Framework\Reflection\TypeProcessor->getGetterReturnType. You just read the @return flag but ignore the use statement.
Comment from Vinai, posted on GitHub Mar 14, 2016
That is a limitation of the PHP interpreter, PHPUnit for example has the same "issue" when parsing @covers and @uses annotations.
The class imports are resolved by the PHP interpreter using a kind of pre-processing of the source code, but the comments are just treated as plain text, not code.
however, any code that tries to apply namespaces to non-fully qualified class names in annotations would not only have to resolve class name imports, but also would have to keep track of the current namspace in the PHP file, which I would imagine would be not that trivial, since PHP allowes multiple namespaces per file.
I also got bitten by not using fully qualified class names in PHPDoc comments, but after some digging I changed the way I thought about them.
Comment from piotrekkaminski, posted on GitHub Jun 14, 2016
@antonkril can you look into it?
Comment from antonkril, posted on GitHub Jul 15, 2016
Yes, it's a limitation of parser. It can be scheduled as improvement.