File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -404,14 +404,14 @@ static zend_always_inline bool _zend_handle_numeric_str(const char *key, size_t
404404 const char * tmp = key ;
405405
406406 if (EXPECTED (* tmp > '9' )) {
407- return 0 ;
407+ return false ;
408408 } else if (* tmp < '0' ) {
409409 if (* tmp != '-' ) {
410- return 0 ;
410+ return false ;
411411 }
412412 tmp ++ ;
413413 if (* tmp > '9' || * tmp < '0' ) {
414- return 0 ;
414+ return false ;
415415 }
416416 }
417417 return _zend_handle_numeric_str_ex (key , length , idx );
@@ -1605,30 +1605,30 @@ static zend_always_inline bool zend_array_is_list(const zend_array *array)
16051605 zend_string * str_idx ;
16061606 /* Empty arrays are lists */
16071607 if (zend_hash_num_elements (array ) == 0 ) {
1608- return 1 ;
1608+ return true ;
16091609 }
16101610
16111611 /* Packed arrays are lists */
16121612 if (HT_IS_PACKED (array )) {
16131613 if (HT_IS_WITHOUT_HOLES (array )) {
1614- return 1 ;
1614+ return true ;
16151615 }
16161616 /* Check if the list could theoretically be repacked */
16171617 ZEND_HASH_PACKED_FOREACH_KEY (array , num_idx ) {
16181618 if (num_idx != expected_idx ++ ) {
1619- return 0 ;
1619+ return false ;
16201620 }
16211621 } ZEND_HASH_FOREACH_END ();
16221622 } else {
16231623 /* Check if the list could theoretically be repacked */
16241624 ZEND_HASH_MAP_FOREACH_KEY (array , num_idx , str_idx ) {
16251625 if (str_idx != NULL || num_idx != expected_idx ++ ) {
1626- return 0 ;
1626+ return false ;
16271627 }
16281628 } ZEND_HASH_FOREACH_END ();
16291629 }
16301630
1631- return 1 ;
1631+ return true ;
16321632}
16331633
16341634
You can’t perform that action at this time.
0 commit comments