Original Post
Ok, i've been fiddling with some ASM code, and I still really suck at it :P but, what am I doing wrong here? Why doesn't this compile? I am using VS 2005 pro. I get this compile error: Is that right? Anyways, thanks for the help, asm is pretty overwhelming!
[source="cpp"]
int length = 0;
char names[10];
cout << "Enter your name:";
cin >> names;
length = strlen(names);
length -= 3;
__asm
{
mov ECX,length <- error on this line
LEA EDI,names
}
error C2400: inline assembler syntax error in 'second operand'; found 'newline'
Also, again probably a dumb question, how do I grab data from a register?
int blah;
__asm
{
MOV blah,EAX ; mov from eax to blah
}