Annotation of embedaddon/php/tests/classes/constants_error_003.phpt, revision 1.1

1.1     ! misho       1: --TEST--
        !             2: Basic class support - attempting to pass a class constant by reference.
        !             3: --FILE--
        !             4: <?php
        !             5:   class aclass
        !             6:   {
        !             7:       const myConst = "hello";
        !             8:   }
        !             9:   
        !            10:   function f(&$a)
        !            11:   {
        !            12:       $a = "changed";
        !            13:   }
        !            14:   
        !            15:   f(aclass::myConst);
        !            16:   var_dump(aclass::myConst);
        !            17: ?>
        !            18: --EXPECTF--
        !            19: 
        !            20: Fatal error: Only variables can be passed by reference in %s on line 12

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