From 1709fa61a4a30fa0f4947cda3823f504530fca4f Mon Sep 17 00:00:00 2001 From: nickysn Date: Thu, 8 Feb 2018 16:13:27 +0000 Subject: [PATCH] + extended test tasm17.pp with 'dw offset @jumptarget', 'dd @jumptarget' and 'dd offset @jumptarget' git-svn-id: trunk@38166 - --- tests/test/tasm17.pp | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/tests/test/tasm17.pp b/tests/test/tasm17.pp index 379f77cb60..22d96004af 100644 --- a/tests/test/tasm17.pp +++ b/tests/test/tasm17.pp @@ -18,7 +18,7 @@ const var expect2: array [0..6] of word; expect3: array [0..6] of word; - expect4: array [0..4] of word; + expect4: array [0..12] of word; procedure test1; assembler; {$IFDEF FPC_MM_HUGE}nostackframe;{$ENDIF} asm @@ -57,6 +57,15 @@ asm dw @jumptarget nop nop + dw offset @jumptarget + nop + nop + dd @jumptarget + nop + nop + dd offset @jumptarget + nop + nop @jumptarget: db 55h, 0aah end; @@ -107,9 +116,17 @@ begin expect4[0] := $9090; expect4[1] := $9090; - expect4[2] := Ofs(test4) + 8; + expect4[2] := Ofs(test4) + 24; expect4[3] := $9090; - expect4[4] := $aa55; + expect4[4] := Ofs(test4) + 24; + expect4[5] := $9090; + expect4[6] := Ofs(test4) + 24; + expect4[7] := Seg(test4); + expect4[8] := $9090; + expect4[9] := Ofs(test4) + 24; + expect4[10] := 0; + expect4[11] := $9090; + expect4[12] := $aa55; if not CompareCode(CodePointer(@test4), @expect4, SizeOf(expect4)) then Error;