[Libreoffice-commits] core.git: i18npool/source

Caolán McNamara caolanm at redhat.com
Sun Jun 18 13:43:47 UTC 2017


 i18npool/source/nativenumber/nativenumbersupplier.cxx |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 876c035dc448314eb6a44cf4692b90188478f797
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jun 18 14:43:01 2017 +0100

    add comment on special case for the 15 and 16 numbers
    
    Change-Id: Iecc46c30b9d4a91339099f5b0b6d8a9ca715b13b

diff --git a/i18npool/source/nativenumber/nativenumbersupplier.cxx b/i18npool/source/nativenumber/nativenumbersupplier.cxx
index 4418fc287c45..492b8da5e421 100644
--- a/i18npool/source/nativenumber/nativenumbersupplier.cxx
+++ b/i18npool/source/nativenumber/nativenumbersupplier.cxx
@@ -862,6 +862,8 @@ void makeHebrewNumber(sal_Int64 value, OUStringBuffer& output, bool isLast, bool
         for (sal_Int32 j = 0; num > 0 && j < sal_Int32(SAL_N_ELEMENTS(HebrewNumberCharArray)); j++) {
             if (num - HebrewNumberCharArray[j].value >= 0) {
                 nbOfChar++;
+                // https://en.wikipedia.org/wiki/Hebrew_numerals#Key_exceptions
+                // By convention, the numbers 15 and 16 are represented as 9 + 6 and 9 + 7
                 if (num == 15 || num == 16) // substitution for 15 and 16
                     j++;
                 num = sal::static_int_cast<sal_Int16>( num - HebrewNumberCharArray[j].value );


More information about the Libreoffice-commits mailing list