I'm going to start by apologizing because I'm a little fuzzy on the terminology here.
I'm evaluating PHPStorm for use at work. Normally I use Eclipse because it's free and it works well most of the time. But I thought I'd give PHPStorm a shot. It's got some really nice features and integrates with Git pretty nicely.
But for whatever reason, I can't get code tracing/ctrl-click-on-a-function-and-it-takes-me-to-the-function-definition working on PHPStorm. I'm working in Magento 2 and that's a bit of a deal breaker for me.
So as an example, let's say I've got this phtml file
<?php
/** @var $block \MyCompany\MyModule\Block\Foo */
$helper = $block->_fooHelper;
$bar = $helper->doSomethingCool();
?>
<h2><?php echo $bar; ?></h2>
In Eclipse, I can ctrl-click on the doSomethingCool() function and it'll open up the class for _fooHelper and take me right to the function definition. But in PHPStorm all I get is a message saying
"Method 'doSomethingCool' not found. Referenced method is not found in subject class."
I've searched around and ran the 'Detect PSR-0 Namespace roots" which came back and labeled the vendor and app/code folders as PSR-0 roots and then ran "Invalidate Cache/Restart" to reindex but I still get the same message.
Any ideas what I need to do to get the code tracing functionality I described working in PHPStorm?
EDIT: I just found that code tracing (i.e. ctrl-click on a function call) works with a type hinting pointing to the vendor folder like
/** var $block \Magento\Backend\Block\Template */
but does not work if it's pointing to something in the app/code folder like
/** var $block \MyCompany\MyModule\Block\Foo */