• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 602
  • Last Modified:

'emit' syntax. MSVC 4.1

I seem to remember there being an 'emit' command that could be used to get past the limitation of '_asm' which cannot do 'db' commands.

I want to create in-line assembler where I specify the hex values for the op-codes. Something like:-

emit {
  0x72
  0x01
}

Can anyone tell me the exact syntax?
0
icd
Asked:
icd
  • 2
1 Solution
 
plarocheCommented:
The command is _emit and it can only define one hex value each time, to do what you want you will need:

__asm {
  _emit 0x72
  _emit 0x01
}

etc...

For more details you can check the doc under _emit
0
 
icdAuthor Commented:
Thanks for the (very) prompt reply. The reason I asked the question was that there appears to be no on-line help for _emit.
0
 
plarocheCommented:
I found the help in the last delivery of MSDN (July 1998 I think) although it is up-to-date for VC 6.0 the _emit syntax did not change.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now