diff options
author | Rene Engelhard <rene@debian.org> | 2020-11-01 18:30:49 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2020-11-01 23:39:37 +0100 |
commit | 9cdcc20dee02a13e065b6117ff0d574e567c6112 (patch) | |
tree | 68bab2cd89b493f8533e2f747e112b8e519d063f /i18npool/source/calendar | |
parent | 17d61ed89bea9e56b5762aeaaf759b7bdb0e14cf (diff) |
fix build with ICU 68
use standard true.
/home/rene/LibreOffice/git/master/i18npool/source/calendar/calendar_gregorian.cxx: In member function 'virtual void i18npool::Calendar_gregorian::setLocalDateTime(double)':
/home/rene/LibreOffice/git/master/i18npool/source/calendar/calendar_gregorian.cxx:363:40: error: 'TRUE' was not declared in this scope
363 | body->getTimeZone().getOffset( fR, TRUE, nZoneOffset, nDSTOffset, status );
| ^~~~
/usr/include/unicode/umachine.h says:
@deprecated ICU 68 Use standard "true" instead.
Change-Id: I45d2b0afa6a9043767af5c2cf41ba24377f2cdc4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105151
Tested-by: René Engelhard <rene@debian.org>
Reviewed-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'i18npool/source/calendar')
-rw-r--r-- | i18npool/source/calendar/calendar_gregorian.cxx | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/i18npool/source/calendar/calendar_gregorian.cxx b/i18npool/source/calendar/calendar_gregorian.cxx index 69fb08797ab3..f05fc96009ca 100644 --- a/i18npool/source/calendar/calendar_gregorian.cxx +++ b/i18npool/source/calendar/calendar_gregorian.cxx @@ -360,7 +360,14 @@ Calendar_gregorian::setLocalDateTime( double fTimeInDays ) "Calendar_gregorian::setLocalDateTime: " << std::fixed << fM << " rounded to " << fR); int32_t nZoneOffset, nDSTOffset; UErrorCode status = U_ZERO_ERROR; - body->getTimeZone().getOffset( fR, TRUE, nZoneOffset, nDSTOffset, status ); + body->getTimeZone().getOffset( fR, +#if U_ICU_VERSION_MAJOR_NUM >= 68 + true, +#else + TRUE, +#endif + nZoneOffset, nDSTOffset, status ); + if ( !U_SUCCESS(status) ) throw ERROR; status = U_ZERO_ERROR; body->setTime( fR - (nZoneOffset + nDSTOffset), status ); |