php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #527 gettype() now even worse!!!
Submitted: 1998-07-09 08:43 UTC Modified: 1998-07-09 19:02 UTC
From: be at SHonline dot DE Assigned:
Status: Closed Package: Misbehaving function
PHP Version: 3.0.1 OS: solaris 2.5.1
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: be at SHonline dot DE
New email:
PHP Version: OS:

 

 [1998-07-09 08:43 UTC] be at SHonline dot DE
Now gettype is totally inconsistent:

Now
-------
$b = array();
 
function b() { ; }
 
print gettype($b);
-------

retruns "array" which is perfectly correct.

But
-------
class A { 
 var $a = array();
 function a() { ; }
}
 
$o = new A;
print gettype($o->a);
-------

returns "user function" which is not only false, but also
inconsistent to what gettype() returns in the upper case.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1998-07-09 19:02 UTC] ssb
[ignoring]

 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Wed Jun 17 17:00:02 2026 UTC