Pursuant to the introspection portion of TODO-PHP5, here is a small
patch that:
- Keeps track of starting/ending line numbers for user functions.
- Removes extraneous T_ML_COMMENT token.
- Stores the last seen doc comment (JavaDoc style) in the compiler
globals for future access by the introspection features and introduces
the new T_DOC_COMMENT token. The doc comment is defined as a multiline
comment starting with "/** \n" and ending with "*/". So, in the
following example:
/**
* @name foo
* @param blah string
*/
function foo($blah)
{
}
The CG(doc_comment) will contain:
* @name foo
* @param blah string
What is left to do here is adding the T_DOC_COMMENT to parser rules and
storing it in the appropriate structures (zend_op_array for functions,
zend_class_entry for classes, etc).
If no one objects, I will commit it shortly.
-Andrei http://www.gravitonic.com/
The Feynman problem solving algorithm:
1) Write down the problem.
2) Think real hard.
3) Write down the answer.
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php