Hello l0t3k, if you really need consts for internal classes you should take a look at zend_API.c:zend_declare_property_*() functions on how to create internal zval's. Also you need to adapt the handling of default properties from zend_compile.c:zend_initialize_class_data() to the constant table.
That we didn't do this yet has something to do with nothing besides the reflection needs it. And for the reflection we go another way. Tuesday, October 21, 2003, 2:41:21 AM, you wrote: > Andi, > is/was someone planning on looking into the problem of class constants > for internal classes? i'll include a comment (from Moriyoshi) in our project > as a reference > /* > * XXX: zend_initialize_class_data() is totally mess! because it > * virtually doesn't take it into account that the constants of > * internal classes are persistently allocated while they will actually > * be destroyed by the normal ZVAL_PTR_DTOR() which accepts zvals > * allocated by emalloc(). > * That's why I prepared my own zval destructors. But this workaround is > * not safe yet because all the symbols bound dynamically by the Zend engine > * are supposed to be released before the destruction of class entries > * registered by extensions at the engine shutdown. > * So this extension has to be linked statically to the PHP runtime for now. > * .. :( > */ > that's the only outstanding issue i have personally with the beta. > otherwise the current CVS works well. ive tested the new read/write > dimension hooks, object level iterators, as well as casting, and they work > as expected. > l0t3k > "Andi Gutmans" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >> Hey, >> >> I'd like to release Beta 2 at the end of the week after next (30th of >> October). Please make sure your code is ready by then. If there's anything >> critical that can't be ready on time please let me know (although I doubt >> there is such a thing). >> Beta 2 will be a big step forward from beta 1 and I think once it's out >> it'll allow us to build the necessary momentum for releasing beta's of PHP >> 5 more often. >> >> Andi -- Best regards, Marcus mailto:[EMAIL PROTECTED] -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php