ASSUME Statements Not Checked

ID Number: Q26663

5.00

MS-DOS

buglist5.00 fixlist5.00a

Problem:

MASM does not check ASSUME statements and generates the MASM Version

4.00 "Can't reach with segment reg" error message when it defaults to

DS:.

The following is an example of this problem:

data segment public byte 'data'

assume cs:nothing

assume ds:data

assume es:nothing

assume ss:nothing

foo dw 0

data ends

code segment public byte 'code'

assume cs:code

assume ds:nothing

assume es:nothing

assume ss:nothing

mov ax,foo

code ends

end

This results in no errors at assembly time. The mov instruction above

will use the DS register even though the code has DS pointing to

garbage. The correct error message is given in MASM Version 4.00 error

68: "Cannot address with segment register."

Response:

Microsoft has confirmed this to be a problem in Version 5.00. This

problem was corrected in MASM Version 5.00a. Call Microsoft Product

Support Services at (206) 646-5109 and request the MASM Version 5.00a

update.