MASM weird error output + solution

DragonautX 1 Reputation point
2021-02-19T03:51:38.923+00:00

The original poster here showed MASM is fixed now, but I just wanted to add this here because there doesn't seem to be another site about it, and someone else might be searching here for help.

~~~

-I'm learning MASM. I tried a hello.asm from the "MASM32 SDK" (separate tool). I commented out "option casemap :none" below, which was wrong.
-In MASM 14.00.24210.0 (VS 2015), I get corrupted output. (1st pic)
-In MASM 14.28.29334.0 (VS 2019), it's ok. (2nd pic)

; ллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллл  

;                 Build this with the "Project" menu using  
;                       "Console Assemble and Link"  

; ллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллл  

    .486                                    ; create 32 bit code  
    .model flat, stdcall                    ; 32 bit memory model  
    ;option casemap :none                    ; case sensitive  

    include \masm32\include\windows.inc     ; always first  
    include \masm32\macros\macros.asm       ; MASM support macros  

  ; -----------------------------------------------------------------  
  ; include files that have MASM format prototypes for function calls  
  ; -----------------------------------------------------------------  
    include \masm32\include\masm32.inc  
    include \masm32\include\gdi32.inc  
    include \masm32\include\user32.inc  
    include \masm32\include\kernel32.inc  

  ; ------------------------------------------------  
  ; Library files that have definitions for function  
  ; exports and tested reliable prebuilt code.  
  ; ------------------------------------------------  
    includelib \masm32\lib\masm32.lib  
    includelib \masm32\lib\gdi32.lib  
    includelib \masm32\lib\user32.lib  
    includelib \masm32\lib\kernel32.lib  

    .code                       ; Tell MASM where the code starts  

; ллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллл  

start:                          ; The CODE entry point to the program  

    print chr$("Hey, this actually works.",13,10)  
    exit  

; ллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллллл  

end start                       ; Tell MASM where the program ends  

69872-masm-error.jpg

69846-masm-okay.jpg

Developer technologies C++
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.