Re: PHPDoc Development Status

From: Date: Fri, 23 Nov 2001 08:19:15 +0000
Subject: Re: PHPDoc Development Status
References: 1 2  Groups: php.dev php.pear.dev 
Request: Send a blank email to php-dev+get-71449@lists.php.net to get a copy of this message
On Thu, 22 Nov 2001 22:17:18 +0100 jan@kneschke.de wrote: > I've written a PHP-2-XML converter which is sitting directly on the > Zend-parser. This gives us more speed and more accuracy. Difficult to do better in fact ... ;) > It has been written because Ulf Wendel convinced me to do it by > delivering a few pizzas. :)) > If someone wants to test it, download it from ŽŽƒ)$äǚ½kAÇ > òhttp://weigon.dyndns.org/ Yeap it works fine :) Some minor bugfixes i've find tonight (diff -u at bottom) > It is a php-extension which requires some patches to the Zend engine. If > someone tests it, don't give up to early. The ext has been written for > 4.0.4pl1 or the like and won't compile with the latest php as the Zend > core has changed. At least it still work with 4.0.6 > Currently missing is the PHPDoc part (the php code) which can handle > XML. What to you thing about a double output for this code : - on a side can generate standart HTML output like 'classical' phpdoc - on the other a docbook output. It could be a good way to obtain more easily pear's enduser doc. Even if the docbook output surely need corrections it could be anyway a nice starting point... --- old_phpdoc.c Fri Nov 23 08:58:31 2001 +++ phpdoc.c Fri Nov 23 08:47:44 2001 @@ -17,6 +17,7 @@ +----------------------------------------------------------------------+ */ + #include "php.h" #include "php_ini.h" #include "php_phpdoc.h" @@ -488,6 +489,14 @@ PHPDOC_STRCAT(new_string, "/>"); st.pos--; break; + case T_INCLUDE: + case T_INCLUDE_ONCE: + case T_REQUIRE: + case T_REQUIRE_ONCE: + zend_sprintf(buffer, "\"/>\n"); + PHPDOC_STRCAT(new_string, buffer); + st.pos--; + break; } break; case '=': @@ -530,6 +539,14 @@ } break; case ',': + switch (find_something(st.stack, st.pos)) { + case T_FUNCTION_PARAM: + zend_sprintf(buffer, "/>"); + PHPDOC_STRCAT(new_string, buffer); + st.pos--; + break; + } + case T_ARRAY: switch (find_something(st.stack, st.pos)) { case T_FUNCTION_PARAM: zend_sprintf(buffer, "/>"); -- Olivier Courtin

« previous php.dev (#71449) next »