File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / Zend / tests / bug63976.phpt
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Mon Jul 22 01:32:17 2013 UTC (11 years, 8 months ago) by misho
Branches: php, MAIN
CVS tags: v5_4_29p0, v5_4_29, v5_4_20p0, v5_4_20, v5_4_17, HEAD
5.4.17

    1: --TEST--
    2: Bug #63976 (Parent class incorrectly using child constant in class property)
    3: --FILE--
    4: <?php
    5: if (1) {
    6:   class Foo {
    7:     const TABLE = "foo";
    8:     public $table = self::TABLE;
    9:   }
   10: }
   11: if (1) {
   12:   class Bar extends Foo {
   13:     const TABLE = "bar";
   14:   }
   15: }
   16: $bar = new Bar();
   17: var_dump($bar->table);
   18: ?>
   19: --EXPECT--
   20: string(3) "foo"

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>