Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Jump to definition/declaration of own function/var #14

Open
roolo opened this Issue · 1 comment

2 participants

@roolo

Hi,
i am missing key feature for me and it's jump to definition( ctrl+ in Netbeans or Aptana). My question is: Has php budle this feature or do you plan to implement it in some near version of this bundle?

@joshvarner

It's not something that I'll be able to take a look at for a bit, unfortunately. I figured I'd jot some notes here for my own memory, as well as to provide a starting point for anyone interested in implementing it and sending in the patch.

Using the tokenizer is probably the best route I can come up with for building the index. PHP's reflection API isn't really an option, since you have to require() the code, which causes it to be executed (not simply parsed). A good first step would probably be to implement a simple version that only scans the file currently being edited. Scanning the entire open project is entirely new beast-- caching the results, detecting changes, etc.

There are a few other things that would need to be handled, like properly detecting the current namespace and taking that into account when resolving the destination class/function.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.