flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
hitertan 17 Mar 2004, 13:26
I'm a newbie in assemble language.Today when i programming i am held by one curious mistake.I have written some simple codes to stand out the mistake:
Code: include '%fasminc%/win32ax.inc' .code start: call testProc invoke ExitProcess,0 proc testProc .testLocal dd ? enter push eax testGoto1: mov eax,3 mov [.testLocal],eax pop eax return .end start the fasm compile output the compile error below: Quote:
But when I comment the label testGoto1:,the codes can be compiled ok. the correct codes is below Code: include '%fasminc%/win32ax.inc' .code start: call testProc invoke ExitProcess,0 proc testProc .testLocal dd ? enter push eax ;testGoto1: mov eax,3 mov [.testLocal],eax pop eax return .end start What's the wrong i'am making? _________________ i like assembly language and i study it in my pleasure time tanshunquan@hotmail.com |
|||
![]() |
|
Iehbr 17 Mar 2004, 13:56
hitertan wrote: I'm a newbie in assemble language.Today when i programming i am held by one curious mistake.I have written some simple codes to stand out the mistake: Use 'stdcall testProc' |
|||
![]() |
|
hitertan 17 Mar 2004, 14:26
aaro wrote: proc defines global testProc label and dot before testLocal makes it child label of testProc, so it comes testProc.testLocal. Now when you define global label(no dot before it) testGoto1 it changes prefix to testGoto1 so after that when you try to access .testLocal it's same as writing testGoto1.testLocal. I see!Thank you very much! ![]() _________________ i like assembly language and i study it in my pleasure time tanshunquan@hotmail.com |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2023, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.