You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 22, 2019. It is now read-only.
Hope explain correctly, example at bottom.
New [new x();] instanced objects works ok, if you CTRL + mouse over the method, you have the click auto-open option and go to the class-method concrete line. The same but using static instace [x::method()] just open the class never goes to the method.
Example:
one.php:
<?php
class MyClass {
public function test() {
}
}
two.php
<?php
require_once("one.php");
$demo = new MyClass();
$demo->test();
MyClass::test();
If you CTRL+click on "->test();" from "$demo->test();" line, file one.php is opened and focused on "public function test()" line.
If you do the same on "::test();" it just open one.php but no focus on the method, just the class declaration.
The silly example is a short class, but long classes (for example adding some string property with long value could be proof for testing) doesn't locate you on the file and could be nice, cause some frameworks (and me) combine static instances with object instances. Ty!
The text was updated successfully, but these errors were encountered:
Hey, thanks for reporting this but Crane doesn't support go-to-definition on methods yet -- only classes. Are you using another PHP code completion plugin?
I'm confused! I was totally sure that ctrl+click feature was from your extension. I have "PHP Extension Pack". I don't know if this add the ctrl+click go-to method feature, but it's working for "$a = new a(); $a->hello();", not for "a::hello()".
Sorry then, maybe not issue, a feature request :)
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hope explain correctly, example at bottom.
New [new x();] instanced objects works ok, if you CTRL + mouse over the method, you have the click auto-open option and go to the class-method concrete line. The same but using static instace [x::method()] just open the class never goes to the method.
Example:
one.php:
two.php
If you CTRL+click on "->test();" from "$demo->test();" line, file one.php is opened and focused on "public function test()" line.
If you do the same on "::test();" it just open one.php but no focus on the method, just the class declaration.
The silly example is a short class, but long classes (for example adding some string property with long value could be proof for testing) doesn't locate you on the file and could be nice, cause some frameworks (and me) combine static instances with object instances. Ty!
The text was updated successfully, but these errors were encountered: