determine the match shorthand target early.

Closes #7554.

This patch determines the `controller#action` directly
in the `match` method when the shorthand syntax is used.
this prevents problems with namespaces and scopes.
Merge pull request #9361 from senny/improved_match_shorthand_syntax

determine the match shorthand target early.