#23273 [NEW]: Defining __set or __get in a class inside of a namespace undefines print_r

From: Date: Fri, 18 Apr 2003 15:46:22 +0000
Subject: #23273 [NEW]: Defining __set or __get in a class inside of a namespace undefines print_r
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-37853@lists.php.net to get a copy of this message
From: tim at timcrider dot com Operating system: Red Hat 8.0 PHP version: 5CVS-2003-04-18 (dev) PHP Bug Type: Class/Object related Bug description: Defining __set or __get in a class inside of a namespace undefines print_r Whenever you define a __set or __get inside of a class within a namespace seems to undefine print_r -----[ class.php ]----- <?php namespace foo { class bar { function __construct() { } function __set($k, $v) { } function __get($k) { } } } ?> -----[ run.php ]----- #!/php5/bin/php -q <?php require_once "class.php"; $a = New foo::bar; print "Trying ".$a->testing."\n"; $a->abc = 123; print_r($a); ?> -----[ config ]----- ./configure --prefix=/php5 \ --with-gettext \ --with-gd=/usr \ --with-jpeg-dir=/usr/local \ --with-mcrypt=/usr/local \ --with-mcal=/usr/local \ --with-ming=/usr/local \ --with-mhash=/usr/local \ --with-mysql=/usr/local/mysql \ --with-zlib=/usr/local \ --with-ncurses \ --with-tiff-dir="/usr/local" \ --with-unixODBC=/usr/local/unixODBC \ --with-xml \ --with-calendar=shared \ --with-png-dir=/usr/local \ --with-freetype=/usr/local \ --with-freetype-dir=/usr/local \ --with-ttf=/usr/local \ --with-openssl=/usr/local \ --with-bz2 \ --with-dom \ --enable-bcmath \ --enable-calendar \ --enable-dio \ --enable-exif \ --enable-ftp \ --enable-gd-native-ttf \ --enable-pcntl \ --enable-shmop \ --enable-sigchild \ --enable-sockets \ --enable-track-vars \ --enable-magic-quotes \ --enable-trans-sid \ --enable-libgcc \ --enable-wddx \ --enable-sysvshm \ --enable-sysvsem \ --enable-sysvmsg -- Edit bug report at http://bugs.php.net/?id=23273&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=23273&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=23273&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=23273&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=23273&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=23273&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=23273&r=support Expected behavior: http://bugs.php.net/fix.php?id=23273&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=23273&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=23273&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=23273&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=23273&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=23273&r=dst IIS Stability: http://bugs.php.net/fix.php?id=23273&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=23273&r=gnused

« previous php.bugs (#37853) next »