I'm testing this structure so that intelliphense works and this doesn't work in some scenario...WHY
this first scenario i use ClassManager and method LoadClass to populate a class object $oclass of owned by father class CoreApp... on this scenario inteliphense not work i cant get Go to Definition:
Part 1: Not work.
class Symbolic_Class
{
public function SymbolicFunction()
{
return 'Symbolic Class Success';
}
}
class ClassManager
{
public function LoadClass()
{
CoreApp::$oclass['MVC']['SYMBOLIC_CALL'] = $this->Symbolic_Class = new Symbolic_Class();
}
}
class CoreApp
{
public static $ovars = null;
public static $oclass = null;
public function goCoreApp()
{
$autoload = new ClassManager();
$autoload->LoadClass();
unset($autoload);
echo '<pre>';
echo var_dump(self::$oclass);
echo '</pre>';
echo self::$oclass['MVC']['SYMBOLIC_CALL']->SymbolicFunction();
}
}
$app = new CoreApp();
$app->goCoreApp();

Part 2: work.
In this other structure, I have deleted the class that is in charge of filling the object. and I have brought the class instance to the parent class. in this inteliphense scanner if it works correctly ??? WHY
class Symbolic_Class
{
public function SymbolicFunction()
{
return 'Symbolic Class Success';
}
}
class CoreApp
{
public static $ovars = null;
public static $oclass = null;
public function goCoreApp()
{
self::$oclass = $this->Symbolic_Class = new Symbolic_Class();
echo self::$oclass->SymbolicFunction();
}
}
$app = new CoreApp();
$app->goCoreApp();

Why the Object populated in a class outside the parent class does not work; and if the instance is made in the same parent class it works correctly ... all the time the parent class object is used to call the function; but it can't if the object is populated outside the parent class IT STOPS WORKING. Why you are not interesting on solving help this???not is a SEARCH TEXT COMPLEMENT, at least test this scenario
also using the structure that supposedly works; if i replace the class text with a variable that contains the class text it also stops working ...
class Symbolic_Class
{
public function SymbolicFunction()
{
return 'Symbolic Class Success';
}
}
class CoreApp
{
public static $ovars = null;
public static $oclass = null;
public function goCoreApp()
{
$text_Class = 'Symbolic_Class';
self::$oclass = $this->$text_Class = new $text_Class();
echo self::$oclass->SymbolicFunction();
}
}
$app = new CoreApp();
$app->goCoreApp();
its plugin only works if the structure has strict syntax:
father Class->
function father->
Instace class child->
call function child()->
if you try to use a different charger it doesn't work
Yes the code works but intelephense does not run the code, it statically analyses it.
https://github.com/bmewburn/vscode-intelephense/issues/1274#issuecomment-653823453
Yes the code works but intelephense does not run the code, it statically analyses it.
ok... neither this nor any other extension does ... returning to Sublime Text 3 with phpintel ... Visual Studio Code, will remain a garbage, while I cannot take advantage of it 100%; regardless of the code structure used ... and the limited vision of the extensions...
I have been used intelephense with ST 4 for quite a while and I am happy actually. But it doesn't fit your "quite dynamic" (which is usually considered as worse maintainability) programming habit indeed, so :shrug:
I have been used intelephense with ST 4 for quite a while and I am happy actually. But it doesn't fit your "quite dynamic" (which is usually considered as worse maintainability) programming habit indeed, so 馃し
Just because it's dynamic doesn't mean it's wrong or that it is more difficult to maintain ... and there is no ST version 4 ...
Just because it's dynamic doesn't mean it's wrong or that it is more difficult to maintain ...
I then leave it to let other people judge your examples.
and there is no ST version 4 ...
Changelog: https://gist.github.com/jfcherng/7bf4103ea486d1f67b7970e846b3a619
If you are a licensed ST 3 user and having interesting in testing ST 4, you can get it in the official Discord chat server.
public function goCoreApp()
{
self::$oclass = $this->Symbolic_Class = new Symbolic_Class();
echo self::$oclass->SymbolicFunction();
}
Intelephense understands SymbolicFunction here because it was able to infer the type of self::$oclass from the assignment in the same scope/context. Your other examples assign to $oclass in a different context. You could be assigning to $oclass in any number of functions/classes with any number of runtime conditions in your project. It is not practical and in many cases not possible to go through all of these to try and understand what type $oclass is.
I've already linked to some documentation on using type declarations and annotations in your other tickets.
public function goCoreApp() { self::$oclass = $this->Symbolic_Class = new Symbolic_Class(); echo self::$oclass->SymbolicFunction(); }Intelephense understands
SymbolicFunctionhere because it was able to infer the type ofself::$oclassfrom the assignment in the same scope/context. Your other examples assign to$oclassin a different context. You could be assigning to$oclassin any number of functions/classes with any number of runtime conditions in your project. It is not practical and in many cases not possible to go through all of these to try and understand what type$oclassis.I've already linked to some documentation on using type declarations and annotations in your other tickets.
I also think you should update the documentation ...
Just because it's dynamic doesn't mean it's wrong or that it is more difficult to maintain ...
I then leave it to let other people judge your examples.
and there is no ST version 4 ...
Changelog: https://gist.github.com/jfcherng/7bf4103ea486d1f67b7970e846b3a619
If you are a licensed ST 3 user and having interesting in testing ST 4, you can get it in the official Discord chat server.
Sure but I know that it will not have support for the ST3 plugin as it happened with the ST2 version, I am not going to wear myself out on something that they do not have the interest to solve.
Sure but I know that it will not have support for the ST3 plugin
Then you will be disappointed. It supports all ST 3 plugins, if it doesn't, it's a bug. The devs mean to make it support all ST 3 plugins.
But one thing for sure, it's under alpha state. I guess I have said too many off-topic chats. The chat server is there anyway.
Check this on ST4:

Work perfect .... Good Work @jfcherng