diff options
author | Gabriel Caruso <carusogabriel34@gmail.com> | 2018-08-19 01:32:00 -0300 |
---|---|---|
committer | Peter Kokot <peterkokot@gmail.com> | 2018-12-03 01:22:14 +0100 |
commit | cdd8368d6f3f000a2e30a6be9976c5539f10fe85 (patch) | |
tree | 8f680d0c1fb552fdcbdbf3d49427c811fa789bf9 /ext/intl/dateformat/dateformat_parse.c | |
parent | 6c16f9b69c1951392d5d0ac89d3fbd2b318af118 (diff) | |
download | php-git-cdd8368d6f3f000a2e30a6be9976c5539f10fe85.tar.gz |
Clean up unnecessary ternary expressions and simplify some returns
- Simplify conditions
- Use ZEND_HASH_APPLY_* instead of hard-coded booleans
- Use ZEND_NORMALIZE_BOOL
- Drop sign in favor of ZEND_NORMALIZE_BOOL
Diffstat (limited to 'ext/intl/dateformat/dateformat_parse.c')
-rw-r--r-- | ext/intl/dateformat/dateformat_parse.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/intl/dateformat/dateformat_parse.c b/ext/intl/dateformat/dateformat_parse.c index a04ef1105e..af96095242 100644 --- a/ext/intl/dateformat/dateformat_parse.c +++ b/ext/intl/dateformat/dateformat_parse.c @@ -116,7 +116,7 @@ static void internal_parse_to_localtime(IntlDateFormatter_object *dfo, char* tex /* Is in DST? */ isInDST = ucal_inDaylightTime(parsed_calendar , &INTL_DATA_ERROR_CODE(dfo)); INTL_METHOD_CHECK_STATUS( dfo, "Date parsing - localtime failed : while checking if currently in DST." ); - add_assoc_long( return_value, CALENDAR_ISDST,(isInDST==1?1:0)); + add_assoc_long( return_value, CALENDAR_ISDST,isInDST==1); } /* }}} */ |