problems and segmentation fault with constants in PHP5

From: Date: Fri, 12 Sep 2003 23:53:56 +0000
Subject: problems and segmentation fault with constants in PHP5
Groups: php.general 
Request: Send a blank email to php-general+get-162484@lists.php.net to get a copy of this message
Is this suppose to work ? Currently it does not. class Priority { const DEBUG = 0; const INFO = 1; const WARN = 2; const ERROR = 3; const FATAL = 4; const MAX_PRIORITY = FATAL; } class ExtendedPriority extends Priority { const REMOTE = Priority::MAX_PRIORITY + 1; const URGENT = Priority::MAX_PRIORITY + 2; } if it's not supposed to work, there is also some parser problem in ZE2 that accepts a constant expression based on string concatenation(This code causes segmentation fault): class test { const TEST = "hi"; const TEST1 = self::TEST . "ih"; } Cristiano Duarte

« previous php.general (#162484) next »