Browse Source

* PChar -> PAnsiChar

Michaël Van Canneyt 2 years ago
parent
commit
d28bbd789c

+ 26 - 26
packages/rtl-extra/src/aix/clocale.inc

@@ -34,32 +34,32 @@
 
 Type
      lconv = record
-          decimal_point     : pchar;
-          thousands_sep     : pchar;
-          grouping          : pchar;
-          int_curr_symbol   : pchar;
-          currency_symbol   : pchar;
-          mon_decimal_point : pchar;
-          mon_thousands_sep : pchar;
-          mon_grouping      : pchar;
-          positive_sign     : pchar;
-          negative_sign     : pchar;
-          int_frac_digits   : char;
-          frac_digits       : char;
-          p_cs_precedes     : char;
-          p_sep_by_space    : char;
-          n_cs_precedes     : char;
-          n_sep_by_space    : char;
-          p_sign_posn       : char;
-          n_sign_posn       : char;
-          left_parenthesis  : char;
-          right_parenthesis : char;
-          int_p_cs_precedes : char;
-          int_p_sep_by_space: char;
-          int_n_cs_precedes : char;
-          int_n_sep_by_space: char;
-          int_p_sign_posn   : char;
-          int_n_sign_posn   : char;
+          decimal_point     : PAnsiChar;
+          thousands_sep     : PAnsiChar;
+          grouping          : PAnsiChar;
+          int_curr_symbol   : PAnsiChar;
+          currency_symbol   : PAnsiChar;
+          mon_decimal_point : PAnsiChar;
+          mon_thousands_sep : PAnsiChar;
+          mon_grouping      : PAnsiChar;
+          positive_sign     : PAnsiChar;
+          negative_sign     : PAnsiChar;
+          int_frac_digits   : AnsiChar;
+          frac_digits       : AnsiChar;
+          p_cs_precedes     : AnsiChar;
+          p_sep_by_space    : AnsiChar;
+          n_cs_precedes     : AnsiChar;
+          n_sep_by_space    : AnsiChar;
+          p_sign_posn       : AnsiChar;
+          n_sign_posn       : AnsiChar;
+          left_parenthesis  : AnsiChar;
+          right_parenthesis : AnsiChar;
+          int_p_cs_precedes : AnsiChar;
+          int_p_sep_by_space: AnsiChar;
+          int_n_cs_precedes : AnsiChar;
+          int_n_sep_by_space: AnsiChar;
+          int_p_sign_posn   : AnsiChar;
+          int_n_sign_posn   : AnsiChar;
        end;
      Tlconv = lconv;
      plconv = ^lconv;

+ 1 - 1
packages/rtl-extra/src/android/clocale.pp

@@ -248,7 +248,7 @@ var
     Result:=utf8string(res);
   end;
 
-  function _GetSeparator(dateStyle: UDateFormatStyle; timeStyle: UDateFormatStyle; DefSep: char): char;
+  function _GetSeparator(dateStyle: UDateFormatStyle; timeStyle: UDateFormatStyle; DefSep: AnsiChar): AnsiChar;
   var
     fmt: UDateFormat;
     err: UErrorCode;

+ 26 - 26
packages/rtl-extra/src/bsd/clocale.inc

@@ -39,30 +39,30 @@
 
 Type
      lconv = record
-          decimal_point     : pchar;
-          thousands_sep     : pchar;
-          grouping          : pchar;
-          int_curr_symbol   : pchar;
-          currency_symbol   : pchar;
-          mon_decimal_point : pchar;
-          mon_thousands_sep : pchar;
-          mon_grouping      : pchar;
-          positive_sign     : pchar;
-          negative_sign     : pchar;
-          int_frac_digits   : char;
-          frac_digits       : char;
-          p_cs_precedes     : char;
-          p_sep_by_space    : char;
-          n_cs_precedes     : char;
-          n_sep_by_space    : char;
-          p_sign_posn       : char;
-          n_sign_posn       : char;
-          int_p_cs_precedes : char;
-          int_n_cs_precedes : char;
-          int_p_sep_by_space: char;
-          int_n_sep_by_space: char;
-          int_p_sign_posn   : char;
-          int_n_sign_posn   : char;
+          decimal_point     : PAnsiChar;
+          thousands_sep     : PAnsiChar;
+          grouping          : PAnsiChar;
+          int_curr_symbol   : PAnsiChar;
+          currency_symbol   : PAnsiChar;
+          mon_decimal_point : PAnsiChar;
+          mon_thousands_sep : PAnsiChar;
+          mon_grouping      : PAnsiChar;
+          positive_sign     : PAnsiChar;
+          negative_sign     : PAnsiChar;
+          int_frac_digits   : AnsiChar;
+          frac_digits       : AnsiChar;
+          p_cs_precedes     : AnsiChar;
+          p_sep_by_space    : AnsiChar;
+          n_cs_precedes     : AnsiChar;
+          n_sep_by_space    : AnsiChar;
+          p_sign_posn       : AnsiChar;
+          n_sign_posn       : AnsiChar;
+          int_p_cs_precedes : AnsiChar;
+          int_n_cs_precedes : AnsiChar;
+          int_p_sep_by_space: AnsiChar;
+          int_n_sep_by_space: AnsiChar;
+          int_p_sign_posn   : AnsiChar;
+          int_n_sign_posn   : AnsiChar;
        end;
      Tlconv = lconv;
      plconv = ^lconv;
@@ -128,7 +128,7 @@ Const
         ABMON_11        = ABMON_1+10;
         ABMON_12        = ABMON_1+11;
         {$if defined(openbsd) or defined(netbsd)}
-        RADIXCHAR       = ABMON_1+12;   { Radix char}
+        RADIXCHAR       = ABMON_1+12;   { Radix AnsiChar}
         THOUSEP         = RADIXCHAR+1;  { separator for thousands }
         YESSTR          = RADIXCHAR+2;  { affirmative response for yes/no queries }
         YESEXPR         = RADIXCHAR+3;  { affirmative response expression }
@@ -141,7 +141,7 @@ Const
         ERA_D_T_FMT     = ERA+2;        { era date and time format string }
         ERA_T_FMT       = ERA+3;        { era time format string }
         ALT_DIGITS      = ERA+4;        { alternative symbols for digits }
-        RADIXCHAR       = ERA+5;        { radix char }
+        RADIXCHAR       = ERA+5;        { radix AnsiChar }
         THOUSEP         = RADIXCHAR+1;  { separator for thousands }
         YESEXPR         = RADIXCHAR+2;  { affirmative response expression }
         NOEXPR          = RADIXCHAR+3;  { negative response expression }

+ 24 - 24
packages/rtl-extra/src/solaris/clocale.inc

@@ -36,30 +36,30 @@
 
 Type
      lconv = record
-          decimal_point     : pchar;
-          thousands_sep     : pchar;
-          grouping          : pchar;
-          int_curr_symbol   : pchar;
-          currency_symbol   : pchar;
-          mon_decimal_point : pchar;
-          mon_thousands_sep : pchar;
-          mon_grouping      : pchar;
-          positive_sign     : pchar;
-          negative_sign     : pchar;
-          int_frac_digits   : char;
-          frac_digits       : char;
-          p_cs_precedes     : char;
-          p_sep_by_space    : char;
-          n_cs_precedes     : char;
-          n_sep_by_space    : char;
-          p_sign_posn       : char;
-          n_sign_posn       : char;
-          int_p_cs_precedes : char;
-          int_p_sep_by_space: char;
-          int_n_cs_precedes : char;
-          int_n_sep_by_space: char;
-          int_p_sign_posn   : char;
-          int_n_sign_posn   : char;
+          decimal_point     : PAnsiChar;
+          thousands_sep     : PAnsiChar;
+          grouping          : PAnsiChar;
+          int_curr_symbol   : PAnsiChar;
+          currency_symbol   : PAnsiChar;
+          mon_decimal_point : PAnsiChar;
+          mon_thousands_sep : PAnsiChar;
+          mon_grouping      : PAnsiChar;
+          positive_sign     : PAnsiChar;
+          negative_sign     : PAnsiChar;
+          int_frac_digits   : AnsiChar;
+          frac_digits       : AnsiChar;
+          p_cs_precedes     : AnsiChar;
+          p_sep_by_space    : AnsiChar;
+          n_cs_precedes     : AnsiChar;
+          n_sep_by_space    : AnsiChar;
+          p_sign_posn       : AnsiChar;
+          n_sign_posn       : AnsiChar;
+          int_p_cs_precedes : AnsiChar;
+          int_p_sep_by_space: AnsiChar;
+          int_n_cs_precedes : AnsiChar;
+          int_n_sep_by_space: AnsiChar;
+          int_p_sign_posn   : AnsiChar;
+          int_n_sign_posn   : AnsiChar;
        end;
      Tlconv = lconv;
      plconv = ^lconv;

+ 7 - 7
packages/rtl-extra/src/unix/clocale.pp

@@ -95,12 +95,12 @@ Const
 {$ifdef netbsd}
   { NetBSD has a new setlocale function defined in /usr/include/locale.h
     that should be used }
-function setlocale(category: cint; locale: pchar): pchar; cdecl; external clib name '__setlocale_mb_len_max_32';
+function setlocale(category: cint; locale: PAnsiChar): PAnsiChar; cdecl; external clib name '__setlocale_mb_len_max_32';
 {$else}
-function setlocale(category: cint; locale: pchar): pchar; cdecl; external clib name 'setlocale';
+function setlocale(category: cint; locale: PAnsiChar): PAnsiChar; cdecl; external clib name 'setlocale';
 {$endif}
 
-function nl_langinfo(__item: cint):Pchar;cdecl;external clib name 'nl_langinfo';
+function nl_langinfo(__item: cint):PAnsiChar;cdecl;external clib name 'nl_langinfo';
 
 procedure GetFormatSettings(out fmts: TFormatSettings);
 
@@ -109,7 +109,7 @@ procedure GetFormatSettings(out fmts: TFormatSettings);
     GetLocaleStr := AnsiString(nl_langinfo(item));
   end;
 
-  function GetLocaleChar(item: cint): char;
+  function GetLocaleChar(item: cint): AnsiChar;
   begin
     GetLocaleChar := nl_langinfo(item)^;
   end;
@@ -127,7 +127,7 @@ procedure GetFormatSettings(out fmts: TFormatSettings);
     end;
   end;
 
-  function IsModifier(const Mods: string; m: char): boolean;
+  function IsModifier(const Mods: string; m: AnsiChar): boolean;
   var
     i: integer;
   begin
@@ -140,7 +140,7 @@ procedure GetFormatSettings(out fmts: TFormatSettings);
     end;
   end;
 
-  function FindSeparator(const s: string; Def: char): char;
+  function FindSeparator(const s: string; Def: AnsiChar): AnsiChar;
   var
     i: integer;
   begin
@@ -357,7 +357,7 @@ begin
   fmts.ThousandSeparator:=GetLocaleChar(__THOUSANDS_SEP);
   Sep := ord(GetLocaleChar(__MON_THOUSANDS_SEP));
   if fmts.ThousandSeparator=#0 then
-    fmts.ThousandSeparator := char(Sep);
+    fmts.ThousandSeparator := AnsiChar(Sep);
   {$endif}
   fmts.DecimalSeparator:=GetLocaleChar(RADIXCHAR);
 end;