mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-04 11:50:17 +02:00
+ bug0149a.pp and bug0149b.pp
This commit is contained in:
parent
e639e7b163
commit
4637fffd8b
10
bugs/bug0149a.pp
Normal file
10
bugs/bug0149a.pp
Normal file
@ -0,0 +1,10 @@
|
||||
unit bug0149a;
|
||||
|
||||
interface
|
||||
|
||||
Const tset = [1,2,3,4,5];
|
||||
c = 1;
|
||||
|
||||
implementation
|
||||
|
||||
end.
|
25
bugs/bug0149b.pp
Normal file
25
bugs/bug0149b.pp
Normal file
@ -0,0 +1,25 @@
|
||||
{there is no crash when tset or c from unit a are used in OuterProcedure,
|
||||
it's only a problem when using them in a nested procedure/function}
|
||||
|
||||
unit bug0149b;
|
||||
|
||||
interface
|
||||
|
||||
uses t2a;
|
||||
|
||||
implementation
|
||||
|
||||
Procedure OuterProcedure;
|
||||
|
||||
function t(a: byte): byte;
|
||||
begin
|
||||
if a = c then t := a else t := 0;
|
||||
if a in tset {probably same bug}
|
||||
then t := a
|
||||
else t := 0
|
||||
end;
|
||||
|
||||
Begin
|
||||
End;
|
||||
|
||||
end.
|
@ -198,3 +198,4 @@ bug0146.pp no sizeof() for var arrays and the size is pushed incorrect
|
||||
bug0147.pp function b; is not allowed in implementation
|
||||
bug0148.pp triple fault exception when setting function result of a declared
|
||||
but not yet implemented function in another function
|
||||
bug0149.pp (a, b) compile bug0149b twice and you'll get a triple exc. fault
|
||||
|
Loading…
Reference in New Issue
Block a user