Explorar o código

Merged revisions 1243-1244 via svnmerge from
svn+ssh://[email protected]/FPC/svn/fpc/trunk

r1243 (peter)
* new test


r1244 (peter)
* fixed psize_t

git-svn-id: branches/fixes_2_0@1245 -

peter %!s(int64=20) %!d(string=hai) anos
pai
achega
8507617f0b
Modificáronse 3 ficheiros con 25 adicións e 1 borrados
  1. 1 0
      .gitattributes
  2. 1 1
      packages/base/libc/glue.inc
  3. 23 0
      tests/webtbs/tw4398.pp

+ 1 - 0
.gitattributes

@@ -6048,6 +6048,7 @@ tests/webtbs/tw4308.pp svneol=native#text/plain
 tests/webtbs/tw4336.pp svneol=native#text/plain
 tests/webtbs/tw4350.pp svneol=native#text/plain
 tests/webtbs/tw4388.pp svneol=native#text/plain
+tests/webtbs/tw4398.pp svneol=native#text/plain
 tests/webtbs/ub1873.pp svneol=native#text/plain
 tests/webtbs/ub1883.pp svneol=native#text/plain
 tests/webtbs/uw0555.pp svneol=native#text/plain

+ 1 - 1
packages/base/libc/glue.inc

@@ -10,7 +10,7 @@ Type
   __long_double_t = Extended;
   P__long_double_t = ^__long_double_t;
   size_t = Cardinal;
-  Psize_t = size_t;
+  Psize_t = ^size_t;
   UInt64 = 0..High(Int64); // Must be unsigned.
   wchar_t = widechar;
   Pwchar_t = ^wchar_t;

+ 23 - 0
tests/webtbs/tw4398.pp

@@ -0,0 +1,23 @@
+{$mode tp}
+
+procedure display(s:string);
+var L:longint;
+begin
+  for l:=1 to length(s) do
+  begin
+    case s[l]of
+    '^':begin
+          INC(L);
+          case s[l] of
+            'M':writeln;
+          else write('^'=s[l]);
+          end;
+        end;
+    else write(s[l]);
+    end;
+  end;
+end;
+
+begin
+DISPLAY('^MHello Line One^M');
+end.