Browse Source

* new tests

git-svn-id: trunk@3266 -
peter 19 years ago
parent
commit
41a894975d
3 changed files with 42 additions and 0 deletions
  1. 2 0
      .gitattributes
  2. 18 0
      tests/webtbs/tw5001.pp
  3. 22 0
      tests/webtbs/tw5023.pp

+ 2 - 0
.gitattributes

@@ -6786,6 +6786,8 @@ tests/webtbs/tw4902.pp -text
 tests/webtbs/tw4922.pp svneol=native#text/plain
 tests/webtbs/tw4950.pp svneol=native#text/plain
 tests/webtbs/tw4999.pp svneol=native#text/plain
+tests/webtbs/tw5001.pp svneol=native#text/plain
+tests/webtbs/tw5023.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

+ 18 - 0
tests/webtbs/tw5001.pp

@@ -0,0 +1,18 @@
+{ Source provided for Free Pascal Bug Report 5001 }
+{ Submitted by "Vincent Snijders" on  2006-04-09 }
+{ e-mail: [email protected] }
+program Project1;
+
+{$mode objfpc}{$H+}
+
+resourcestring
+  s = 'test';
+
+begin
+  writeln(s);
+  readln;
+  if length(s)=0
+    then halt(1);
+  if (s<>'test')
+    then halt(1);
+end.

+ 22 - 0
tests/webtbs/tw5023.pp

@@ -0,0 +1,22 @@
+unit tw5023;
+
+{$ifdef fpc}{$mode delphi}{$H+}{$endif}
+
+interface
+
+type
+  TScanLine = array of Integer;
+
+implementation
+
+procedure TestSwap(var A, B: Integer);
+begin
+  // do something
+end;
+
+procedure Main(const ALine: TScanLine);
+begin
+  TestSwap(ALine[0], ALine[1]);  // <-- error here
+end;
+
+end.