ID: 28854
User updated by: toppi at kacke dot de
Reported By: toppi at kacke dot de
Status: Open
Bug Type: *General Issues
Operating System: linux/unix
PHP Version: 5.0.0RC3
New Comment:
Yes right.
I figured out, that i used always , until yet, error_reporting(7) as
default error level.
Try
classA.php
<?
Class a {
var $ssl;
var $ssl;
var $ssl;
function a (){
$ssl = true;
}
}
?>
and
test.php
<?
error_reporting(7);
include "classA.php";
echo "Hello";
exit;
?>
and nothing will happen. NO fatal error, no hello displayed.
Are the error_levels cahnged in php 5 yet ?
Previous Comments:
------------------------------------------------------------------------
[2004-06-21 23:43:42] rodolfo at rodsoft dot org
The correct way to declare the member variables would be:
var $a. This way, your example would be:
class a
{
var $a;
var $b;
var $a;
}
which would give the correct fatal error:
Fatal error: Cannot redeclare a::$a in /var/www/htdocs/tst.php on line
5
------------------------------------------------------------------------
[2004-06-20 16:27:55] toppi at kacke dot de
Description:
------------
Class and Vars
Declare a var twice
Script breaks without error when including
Reproduce code:
---------------
class a {
var a;
var b;
var a;
function a(){
//
}
}
Expected result:
----------------
any warning/error
Actual result:
--------------
script ends/break regular @ including-point
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=28854&edit=1