浏览代码

* make unicodechar equivalent to widechar, resolves #12233

git-svn-id: trunk@11830 -
florian 17 年之前
父节点
当前提交
f64dbd70cf
共有 3 个文件被更改,包括 15 次插入1 次删除
  1. 1 0
      .gitattributes
  2. 1 1
      rtl/inc/systemh.inc
  3. 13 0
      tests/webtbs/tw12233.pp

+ 1 - 0
.gitattributes

@@ -8562,6 +8562,7 @@ tests/webtbs/tw12202.pp svneol=native#text/plain
 tests/webtbs/tw12214.pp svneol=native#text/plain
 tests/webtbs/tw1222.pp svneol=native#text/plain
 tests/webtbs/tw1223.pp svneol=native#text/plain
+tests/webtbs/tw12233.pp svneol=native#text/plain
 tests/webtbs/tw1228.pp svneol=native#text/plain
 tests/webtbs/tw1229.pp svneol=native#text/plain
 tests/webtbs/tw1250.pp svneol=native#text/plain

+ 1 - 1
rtl/inc/systemh.inc

@@ -351,7 +351,7 @@ Type
   PUCS2Char           = PWideChar;
   PWideString         = ^WideString;
 
-  UnicodeChar         = type WideChar;
+  UnicodeChar         = WideChar;
   PUnicodeChar        = ^UnicodeChar;
 {$ifdef VER2_2}
   { this is only to avoid too much ifdefs in the code }

+ 13 - 0
tests/webtbs/tw12233.pp

@@ -0,0 +1,13 @@
+program postest;
+
+{$mode objfpc}{$H+}
+
+var
+  wchar: WideChar;
+  wstring: WideString;
+
+begin
+  wchar := 'a';
+  wstring := 'badc';
+  writeln(Pos(wchar, wstring));
+end.