]> granicus.if.org Git - php/commitdiff
fix error message (reported by Felipe Nascimento)
authorAntony Dovgal <tony2001@php.net>
Mon, 12 Nov 2007 16:55:28 +0000 (16:55 +0000)
committerAntony Dovgal <tony2001@php.net>
Mon, 12 Nov 2007 16:55:28 +0000 (16:55 +0000)
Zend/tests/errmsg_038.phpt
Zend/zend_compile.c

index fdab803ba85e046b109161106ee57acd95c8117a..2927e945fee9eb460b4a96f8f1a2f23e0fdc9bde 100644 (file)
@@ -10,4 +10,4 @@ class test {
 echo "Done\n";
 ?>
 --EXPECTF--    
-Fatal error: Cannot declare property test::$var final, the final modifier is allowed only for methods in %s on line %d
+Fatal error: Cannot declare property test::$var final, the final modifier is allowed only for methods and classes in %s on line %d
index 5582beded0d04719a0ed91c658811bccad980833..588159aea4bd069f45eae807e1cf04ef61528462 100644 (file)
@@ -3537,7 +3537,7 @@ void zend_do_declare_property(znode *var_name, znode *value, zend_uint access_ty
        }
 
        if (access_type & ZEND_ACC_FINAL) {
-               zend_error(E_COMPILE_ERROR, "Cannot declare property %v::$%R final, the final modifier is allowed only for methods",
+               zend_error(E_COMPILE_ERROR, "Cannot declare property %v::$%R final, the final modifier is allowed only for methods and classes",
                        CG(active_class_entry)->name, Z_TYPE(var_name->u.constant), Z_UNIVAL(var_name->u.constant));
        }