我刚安装了emu8086,出现奇怪的错误,我不明白mov ax, SEG datahere
。它看起来不认识SEG关键字。为什么?代码在TASM + DosBox或GUI Turbo Assembler中编译得很好。Mov seg到emu8086的斧头错误
.model small
ASSUME CS: codehere, DS:datahere, SS:stackhere
datahere segment para public 'DATA'
; data segment goes here
datahere ends
stackhere segment word stack 'STACK'
dw 400h dup (00)
stackhere ends
codehere segment para public 'CODE'
start:
mov ax, SEG datahere
mov ds, ax
; code goes here
; END
mov ah, 4ch
int 21h
codehere ends
end start
错误:
wrong parameters: MOV ax, SEG datahere
probably no zero prefix for hex; or no 'h' suffix; or wrong addressing; or undefined var: (ITSELF)
确保您正确地复制了所有内容。特别是,你有'datah segment'还有'MOV ax,SEG duomenys' ??? – Jester
固定,只是错字。我100%确定代码本身在TASM或GUI Turbo Aseembler中工作。我刚刚删除了堆栈公园和其他不需要的代码。 – Dancia