I'm wondering about some situations involving code completion and objects being passed to functions. Basically objects passed to functions are not recognized inside teh functions.
In the following code where a db object is instantiated outside of a function, and then passed to the function, code completion will NOT work within the function.
function test_object($db) {
$db->readdb->
}
$db = new db();
echo test_object($db);
|
In the above example if you try to use code completion it says
"Code completion is not available due to the following error(s):
Failed to identify type of "$db" local variable"
However, if you globalize $db inside the test_object function, then code completion works perfectly.