FIX: EXTERNDEF on PROC Labels Does Not Make Them Public (123728)



The information in this article applies to:

  • Microsoft Macro Assembler (MASM) 6.0
  • Microsoft Macro Assembler (MASM) 6.1

This article was previously published under Q123728

SYMPTOMS

When using MASM version 5.1 compatibility mode, adding an EXTERNDEF to a PROC label does not make it public.

RESOLUTION

Add PUBLIC to the procedures that need to be made public.

STATUS

Microsoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. This bug was corrected in MASM version 6.11.

MORE INFORMATION

The following sample code can be used to demonstrate the problem. The result is "error L2029: 'PROCA' unresolved external."

Sample Code

; TEST1.ASM

   externdef proca:near
   _text segment word public 'CODE'
   call proca
   _text ends
   end
				
-----------
; TEST2.ASM

   externdef proca:near
   _text segment word public 'CODE'
   proca proc near
   ret
   proca endp
   _text ends
   end
				

Modification Type:MinorLast Reviewed:2/11/2004
Keywords:kbfix KB123728