On Sun, 05 Feb 2012 14:08:17 -0800, Stas Malyshev wrote:
Another thing - is there any way to give CLANG some hints about some
functions - such as the fact that zend_error(E_ERROR) does not return
or just make some exceptions when we know some situation that it
thinks can happen does not in fact happen - such as revtal_ptr_ptr =
&retval_ptr and then passing retval_ptr_ptr would actually change
retval_ptr somewhere on the way, etc.
The idea is if we could weed out false positives and somehow mark
them we could use this tool in CI for detecting real errors.

Perhaps those instances could be replaced by zend_error_noreturn. That variant has the "noreturn" attribute, which signals the function never returns. This useful for suppressing those kind of warnings (note C11 also added a standard __Noreturn).

--
Gustavo Lopes

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to