ID: 19411
User updated by: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
-Status: Bogus
+Status: Open
Bug Type: Feature/Change Request
Operating System: All
PHP Version: 4.2.2
New Comment:
It's a FEATURE REQUEST, not a support question.
Currently, PHP's error message when encountering:
class foo {
the SECOND time simply tells me it's "already defined".
While that would be useful if I was, say, including the same
file twice, it's not particularly useful when trying to
integrate two (or more) object-oriented 3rd-party libraries.
The error message would be infinitely more useful if it
included the __FILE__ and __LINE__ of the first:
class foo {
This is essentially the same problem/solution as the old
"headers already sent" problem, which now explicitly states
which line/file caused the original out
Previous Comments:
------------------------------------------------------------------------
[2002-09-17 21:12:27] [EMAIL PROTECTED]
Sorry, but the bug system is not the appropriate forum for asking
support questions. Your problem does not imply a bug in PHP itself.
For a list of more appropriate places to ask for help using PHP,
please visit http://www.php.net/support.php
Thank you for your interest in PHP.
------------------------------------------------------------------------
[2002-09-14 22:13:28] [EMAIL PROTECTED]
It would be Really Nifty (tm) if the class system would tell
me *WHERE* somebody has already defined "class foo" when it
won't let me create class foo because it already exists.
Some bozo is making me use "class User" (how original) but
I've got no idea where the *other* class User is and which
one will be less hassle to change, and PHP ain't telling :-(
I hate inexperienced OO programmers. They cause more
problems than if we just made them not use OO in the first
p
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=19411&edit=1