Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
ZEND_API zend_bool ZEND_FASTCALL instanceof_function(zend_class_entry *instance_ce, const zend_class_entry *ce) /* {{{ */
{
zend_bool matched = 0;
if (instance_ce->last_interface_match == ce) {
return 1;
}
if (ce->ce_flags & ZEND_ACC_INTERFACE) {
matched = instanceof_interface(instance_ce, ce);
} else {
matched = instanceof_class(instance_ce, ce);
}
if (matched) {
instance_ce->last_interface_match = ce;
}
return matched;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.