mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-05-01 05:13:43 +02:00

of the jdk15 unit in that case) * adjusted testall.sh script so it can also be used to test class files compiled for Android (still with the JVM though) git-svn-id: branches/jvmbackend@19835 -
32 lines
460 B
ObjectPascal
32 lines
460 B
ObjectPascal
program tnestedset;
|
|
|
|
{$mode delphi}
|
|
|
|
uses
|
|
{$ifdef java}jdk15{$else}androidr14{$endif};
|
|
|
|
type
|
|
tnestedfpstructenum = (ea,eb,ec);
|
|
tnestedfpstructenumset = set of tnestedfpstructenum;
|
|
|
|
procedure test(var s: tnestedfpstructenumset);
|
|
|
|
procedure sub;
|
|
begin
|
|
s:=s+[eb];
|
|
end;
|
|
|
|
|
|
begin
|
|
sub
|
|
end;
|
|
|
|
var
|
|
s: tnestedfpstructenumset;
|
|
begin
|
|
test(s);
|
|
if s<>[eb] then
|
|
raise jlexception.create;
|
|
jlsystem.fout.println(jlstring(juenumset(@s).toString));
|
|
end.
|