From e68656205c90d7cde79fa5813c2c1f6b1bb1d77a Mon Sep 17 00:00:00 2001 From: pierre Date: Tue, 29 Jan 2002 15:48:21 +0000 Subject: [PATCH] + test output_format dir --- tests/test/README | 3 ++- tests/test/tasout.pp | 28 ++++++++++++++++++++++++++++ tests/test/utasout.pp | 27 +++++++++++++++++++++++++++ 3 files changed, 57 insertions(+), 1 deletion(-) create mode 100644 tests/test/tasout.pp create mode 100644 tests/test/utasout.pp diff --git a/tests/test/README b/tests/test/README index bd92ba2bf7..c2dc05d0c0 100644 --- a/tests/test/README +++ b/tests/test/README @@ -12,7 +12,7 @@ valid for that node. 'Natural type' is a signed 32-bit value on 32-bit architectures. 'Natural type' is a signed 64-bit value on 64-bit architectures. -secondadd() ........... /cg/taddbool.pp Boolean arithmetic operations +secondadd() ........... /cg/taddbool.pp Boolean arithmetic operations secondadd() ........... /cg/taddcard.pp Cardinal arithmetic operations secondadd() ........... /cg/taddreal.pp Real arithmetic operations secondadd() ........... /cg/taddlong.pp Longint arithmetic operations @@ -111,6 +111,7 @@ Floating Point ........ tfpu1.pp tfpu2.pp Assembler readers.......tasmread.pp tests for support of unit or program specifier testmovd.pp testspecial issues about MOVD instruction + tasout.pp tests a problem if a unit is compiled with nasm -------------------------------------------------------------------- RTL diff --git a/tests/test/tasout.pp b/tests/test/tasout.pp new file mode 100644 index 0000000000..88bd929661 --- /dev/null +++ b/tests/test/tasout.pp @@ -0,0 +1,28 @@ +{ %CPU=i386 } + +{$define dummy} +{$ifdef win32} +{$output_format asw} +{$undef dummy} +{$endif win32} + +{$ifdef go32v2} +{$output_format as} +{$undef dummy} +{$endif go32v2} + +{$ifdef linux} +{$output_format as} +{$undef dummy} +{$endif linux} + +{$ifdef dummy} +const + x = ' this is a dummy test'; +{$else} +uses utasout; +{$endif} + +begin + Writeln('x = ',x); +end. diff --git a/tests/test/utasout.pp b/tests/test/utasout.pp new file mode 100644 index 0000000000..0c0c08ec4c --- /dev/null +++ b/tests/test/utasout.pp @@ -0,0 +1,27 @@ +{ requires nasm } + +{$ifdef win32} +{$output_format nasmwin32} +{$endif win32} + +{$ifdef go32v2} +{$output_format nasmcoff} +{$endif go32v2} + +{$ifdef linux} +{$output_format nasmelf} +{$endif linux} + + +unit utasout; + +interface + +var + x : longint; + +implementation + +begin + x:=2; +end.