To add to that, parameters and return values that are boolean should be denoted as such, e.g. the `raw` parameter here and the return value of `match` should be `zend_bool`. Furthermore I'd suggest to use minimal necessary amount of indirection, e.g. the `zval **val` argument of `match` could just as well be `zval *val` unless I'm missing something.