Typehinting merge #50

Merged
belliash merged 298 commits from typehinting into master 2019-04-17 11:27:52 +02:00
Showing only changes of commit 46a3bd85b0 - Show all commits

View File

@ -5625,6 +5625,11 @@ PH7_PRIVATE sxi32 PH7_HashmapWalk(
/* All done */
return SXRET_OK;
}
/*
* Iterate through hashmap entries and typecast all of them recursively to specified type.
* If all elements are compatible with each other and can be safely typecasted w/o data loss
* the SXRET_OK is returned. Otherwise, SXERR_NOMATCH is returned.
*/
PH7_PRIVATE sxi32 PH7_HashmapCast(ph7_value *pObj, sxi32 nType) {
sxi32 rc;
if((pObj->iFlags & MEMOBJ_HASHMAP)) {