@@ -374,9 +374,9 @@ def get_plus_sign_symbol(
374374 >>> get_plus_sign_symbol('en_US')
375375 '+'
376376 >>> get_plus_sign_symbol('ar_EG', numbering_system='default')
377- '\u061c +'
377+ '\\ u061c+'
378378 >>> get_plus_sign_symbol('ar_EG', numbering_system='latn')
379- '\u200e +'
379+ '\\ u200e+'
380380
381381 :param locale: the `Locale` object or locale identifier. Defaults to the system numeric locale.
382382 :param numbering_system: The numbering system used for fetching the symbol. Defaults to "latn".
@@ -397,9 +397,9 @@ def get_minus_sign_symbol(
397397 >>> get_minus_sign_symbol('en_US')
398398 '-'
399399 >>> get_minus_sign_symbol('ar_EG', numbering_system='default')
400- '\u061c -'
400+ '\\ u061c-'
401401 >>> get_minus_sign_symbol('ar_EG', numbering_system='latn')
402- '\u200e -'
402+ '\\ u200e-'
403403
404404 :param locale: the `Locale` object or locale identifier. Defaults to the system numeric locale.
405405 :param numbering_system: The numbering system used for fetching the symbol. Defaults to "latn".
@@ -607,7 +607,7 @@ def format_compact_decimal(
607607 >>> format_compact_decimal(21000000, format_type="long", locale="mk")
608608 '21 милион'
609609 >>> format_compact_decimal(12345, format_type="short", locale='ar_EG', fraction_digits=2, numbering_system='default')
610- '12٫34\xa0 ألف'
610+ '12٫34\\ xa0ألف'
611611
612612 :param number: the number to format
613613 :param format_type: Compact format to use ("short" or "long")
@@ -692,16 +692,16 @@ def format_currency(
692692 >>> format_currency(1099.98, 'EUR', locale='de_DE')
693693 '1.099,98\\ xa0\\ u20ac'
694694 >>> format_currency(1099.98, 'EGP', locale='ar_EG', numbering_system='default')
695- '\u200f 1٬099٫98\xa0 ج.م.\u200f '
695+ '\\ u200f1٬099٫98\\ xa0ج.م.\ \ u200f'
696696
697697 The format can also be specified explicitly. The currency is
698698 placed with the '¤' sign. As the sign gets repeated the format
699699 expands (¤ being the symbol, ¤¤ is the currency abbreviation and
700700 ¤¤¤ is the full name of the currency):
701701
702- >>> format_currency(1099.98, 'EUR', '\xa4 \xa4 #,##0.00', locale='en_US')
702+ >>> format_currency(1099.98, 'EUR', '\\ xa4\ \ xa4 #,##0.00', locale='en_US')
703703 'EUR 1,099.98'
704- >>> format_currency(1099.98, 'EUR', '#,##0.00 \xa4 \xa4 \xa4 ', locale='en_US')
704+ >>> format_currency(1099.98, 'EUR', '#,##0.00 \\ xa4\\ xa4\ \ xa4', locale='en_US')
705705 '1,099.98 euros'
706706
707707 Currencies usually have a specific number of decimal digits. This function
@@ -858,7 +858,7 @@ def format_compact_currency(
858858 >>> format_compact_currency(123456789, 'USD', locale='en_US', fraction_digits=2)
859859 '$123.46M'
860860 >>> format_compact_currency(123456789, 'EUR', locale='de_DE', fraction_digits=1)
861- '123,5\xa0 Mio.\xa0 €'
861+ '123,5\\ xa0Mio.\ \ xa0€'
862862
863863 :param number: the number to format
864864 :param currency: the currency code
@@ -916,7 +916,7 @@ def format_percent(
916916
917917 The format pattern can also be specified explicitly:
918918
919- >>> format_percent(25.1234, '#,##0\u2030 ', locale='en_US')
919+ >>> format_percent(25.1234, '#,##0\\ u2030', locale='en_US')
920920 '25,123‰'
921921
922922 By default the locale is allowed to truncate and round a high-precision
0 commit comments