# Minor Zend Engine Niggle

- Thread: https://externals.io/message/9902
- Original archive: https://news-web.php.net/php.internals/9902
- Started by l0t3k on 2004-05-17T18:15:11+00:00
- Messages: 1
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #9902 — l0t3k — 2004-05-17T18:15:11+00:00

URL: https://externals.io/message/9902#9902

ive noticed in all the OOP extensions callbacks for properties that the
"member" (property name) is not guaranteed to be a string zval.
is there a reason for this, given that any other type should have choked the
lexer in the first place ? even if not, then can the casting be done in the
engine as opposed to the extensions ?

what im referring to is the common idiom


if (member->type != IS_STRING) {
tmp_member = *member;
zval_copy_ctor(&tmp_member);
convert_to_string(&tmp_member);
member = &tmp_member;
}

......

 if (member == &tmp_member) {
zval_dtor(member);
}

in read_property and write_property handlers.


l0t3k
