diff --git a/ext/standard/array.c b/ext/standard/array.c index 9f7709092dde..0ef700f14a74 100644 --- a/ext/standard/array.c +++ b/ext/standard/array.c @@ -3763,7 +3763,7 @@ PHP_FUNCTION(array_unshift) zend_hash_next_index_insert_new(&new_hash, &args[i]); } - ZEND_HASH_FOREACH_STR_KEY_VAL(Z_ARRVAL_P(stack), key, value) { + ZEND_HASH_MAP_FOREACH_STR_KEY_VAL(Z_ARRVAL_P(stack), key, value) { if (key) { zend_hash_add_new(&new_hash, key, value); } else {