Pārlūkot izejas kodu

* handle any char constant -> p(wide)char conversions via cunicodestringtype
because the compiler cannot convert arbitrary unicodechar constants at
compile time to a shortstring (since it doesn't know the code page to use)
(test part of next commit)

git-svn-id: branches/cpstrrtl@25429 -

Jonas Maebe 12 gadi atpakaļ
vecāks
revīzija
b3b404db4b
1 mainītis faili ar 4 papildinājumiem un 4 dzēšanām
  1. 4 4
      compiler/ncnv.pas

+ 4 - 4
compiler/ncnv.pas

@@ -1458,10 +1458,10 @@ implementation
 
       begin
          result:=nil;
-         if is_pwidechar(resultdef) then
-           inserttypeconv(left,cunicodestringtype)
-         else
-           inserttypeconv(left,cshortstringtype);
+         { handle any constants via cunicodestringtype because the compiler
+           cannot convert arbitrary unicodechar constants at compile time to
+           a shortstring (since it doesn't know the code page to use) }
+         inserttypeconv(left,cunicodestringtype);
          { evaluate again, reset resultdef so the convert_typ
            will be calculated again and cstring_to_pchar will
            be used for futher conversion }