News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

type coercion

Started by Jorrj, January 22, 2009, 02:03:49 AM

Previous topic - Next topic

Jorrj

Hello, this is my first post.  I've been reading AoA and enjoying it so far...almost done with chapter 3.  I just finished writing a program and had a little bit of trouble with type coercion.

I was trying to take input into eax as type int32 using:


stdin.get((type int32 eax));


Basically, it didn't work.  I ran a few tests, such as outputting eax immediately after the input, and found that it literally is not putting the value inputted into eax.  Type coercion seems to work fine for outputting eax or for input on other registers (ebx, at least).

In the end, I use stdin.geti32() to properly fetch the input into eax, but I was hoping for some consistency (taking input into eax the same way as ebx).  Was I doing something wrote or did I end up handling it the way it's meant to be?

Also, I wasn't really sure where to ask this as this is the first real community on assembly language I've been able to find, but is HLA a good place for me to be?  Will I eventually learn full blown assembly or will I always be using HLA's higher-level commands?  Thanks for any and all help!