blob: 1965ebe921195daee34104fb5f6d46b143f42dae (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
{ %CPU=i8086 }
program tasmpublic2;
{$goto on}
{$asmmode intel}
label
test_gLoBaL_label;
var
codeseg_var: Word; external name 'test_gLoBaL_label';
v: Word;
begin
asm
public test_gLoBaL_label
jmp @@skip
db 'some garbage here'
test_gLoBaL_label:
dw 1234h
@@skip:
mov ax, cs:[codeseg_var]
mov v, ax
end;
if v<>$1234 then
begin
Writeln('Error!');
Halt(1);
end
else
Writeln('Ok!');
end.
|