I am using Visual C++ 6.0 in Windows XP. Is there a way that I can code assembly with C and compile it?
Thanks
I am using Visual C++ 6.0 in Windows XP. Is there a way that I can code assembly with C and compile it?
Thanks
Inline Assembler from MSDN
It says C++, but it you read it says it works for both C and C++. Also, Google is Your Friend... Search the Web... Read the ' Manual... and all that junk.
Last edited by Ken Fitlike; 10-04-2006 at 05:38 AM. Reason: Please do NOT attempt to bypass the profanity filter; it's there for a very good reason.
Sent from my iPadŽ
Thanks
Every time that I use __asm{} in C, it gives an access violation error when I use the int command(interrupt). And thats if it doesn't freeze first.
Please help!
Post code?
Note that modern operating systems don't let you freely do interrupts and will kill your app if you attempt to.
All the buzzt!
CornedBee
"There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
- Flon's Law
>Post code?
If I just type
and if I click on the __asm statement I freezesCode:__asm { }
Why would it do that? BTW, I can use Notepad to write assembly and it works.Originally Posted by CornedBee
Wow, your compiler freezes when you click on some text!Code:and if I click on the __asm statement I freezes
What did you mean by that sentence?
"The Internet treats censorship as damage and routes around it." - John Gilmore
Maybe code editor, not the compiler.Wow, your compiler freezes when you click on some text!
Applications don't have such low level accesses in modern OSes.Why would it do that?
Learn C++ (C++ Books, C Books, FAQ, Forum Search)
Code painter latest version on sourceforge DOWNLOAD NOW!
Download FSB Data Integrity Tester.
Siavosh K C
> when I use the int command(interrupt).
VC6 is a 32 bit compiler, running on a 32-bit OS.
16-bit real-mode interrupts are just a really bad idea.
Now, which int() are you trying to call, so we can tell you which is the most likely win32 API call to use in it's place.
If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
If at first you don't succeed, try writing your phone number on the exam paper.