Browse Source

* new bugs

peter 20 years ago
parent
commit
2dbc4a8d6b

+ 22 - 0
tests/tbf/tb0173.pp

@@ -0,0 +1,22 @@
+{ %fail }
+
+{ use a structured type used to keep the namings clean }
+type
+   tLoopParm =
+   record
+      Min,
+      Max,
+      Cur : word;
+   end {tLoopParm};
+var
+   One,
+   Two,
+   Three,
+   Four : tLoopParm;
+begin
+   One.Min := 42;
+   One.Max := 42;
+   for One.Cur := One.Min to One.Max do
+   begin
+   end {for One};
+end {Bug}.

+ 0 - 13
tests/webtbf/tw3158.pp

@@ -1,13 +0,0 @@
-{ %fail }
-
-{ Source provided for Free Pascal Bug Report 3158 }
-{ Submitted by "Michalis Kamburelis" on  2004-06-11 }
-{ e-mail: [email protected] }
-{$R+}
-{$Q+}
-
-var A:Single;
-begin
- A:=Exp(800);
- Writeln(A);
-end.

+ 13 - 0
tests/webtbf/tw3562.pp

@@ -0,0 +1,13 @@
+{ %fail }
+{ %opt=-Sew }
+
+procedure p;
+var
+  j : longint;
+begin
+  for j:=1 TO j do;
+end;
+
+begin
+end.
+  

+ 10 - 0
tests/webtbs/tw3546.pp

@@ -0,0 +1,10 @@
+{$ifdef fpc}{$goto on}{$endif}
+
+label 000,01,1;
+begin
+  goto 000;
+  writeln('1');
+
+000:
+  writeln('2');
+end.

+ 29 - 0
tests/webtbs/tw3578.pp

@@ -0,0 +1,29 @@
+{ Source provided for Free Pascal Bug Report 3578 }
+{ Submitted by "Martin Schreiber" on  2005-01-21 }
+{ e-mail:  }
+program project1;
+
+{$mode objfpc}{$H+}
+uses
+  Classes;
+
+type
+ widestringarty = array of widestring;
+
+procedure proc(const ar1,ar2: array of widestring);
+begin
+end;
+
+function getarray: widestringarty;
+begin
+ result:= nil;
+end;
+
+var
+ ar1,ar2: widestringarty;
+begin
+ proc(ar1,ar2);            //ok
+ proc(ar1,getarray);       //ok
+ proc(getarray,ar2);       //ok
+ proc(getarray,getarray);  //Internal error 9999
+end.

+ 18 - 0
tests/webtbs/tw3612.pp

@@ -0,0 +1,18 @@
+{ Source provided for Free Pascal Bug Report 3612 }
+{ Submitted by "Alexey Barkovoy" on  2005-01-30 }
+{ e-mail: [email protected] }
+var
+  str: array[0..200] of WideChar;
+  w: PWideChar;
+  s: String;
+begin
+  str:= 'abcdefgh';
+  w:= str;
+  s:= w;
+  WriteLn(s);
+  w:= str + 2;
+  s:= w;
+  WriteLn(s); // will output "bcdefgh" instead of "cdefgh"
+  if s<>'cdefgh' then
+    halt(1);
+end.

+ 19 - 0
tests/webtbs/tw3617.pp

@@ -0,0 +1,19 @@
+{ %cpu=i386 }
+
+{ Source provided for Free Pascal Bug Report 3617 }
+{ Submitted by "Thomas Schatzl" on  2005-01-31 }
+{ e-mail:  }
+
+{$ifdef fpc}{$asmmode intel}{$endif}
+
+function Div64by32( var X : Int64; Y : Longint ) : Longint
+; assembler;
+asm
+  mov ecx, edx
+  mov edx, [eax+4].longint
+  mov eax, [ eax ].dword
+  idiv ecx
+end;
+
+begin
+end.

+ 17 - 0
tests/webtbs/tw3619.pp

@@ -0,0 +1,17 @@
+{ %cpu=i386 }
+
+{ Source provided for Free Pascal Bug Report 3619 }
+{ Submitted by "Thomas Schatzl" on  2005-01-31 }
+{ e-mail:  }
+program Project2;
+
+{$asmmode intel}
+
+procedure x(bpp : longint); assembler;
+asm
+  MOV BL,4
+  SUB bl, byte ptr [bpp]
+end;
+
+begin
+end.