A89: Re: Storing addresses to pointers
[Prev][Next][Index][Thread]
A89: Re: Storing addresses to pointers
Hi!
> According to what I have read, you cannot store an immediate value
> (or any non-pointer variable) to a pointer variable.
You CAN do this, but the compiler will emit a warning. I.e. this
statement will produce a warning:
char *address;
address=0x4C00;
> You can only copy pointers of the same type and such. Now, the books
> may say this, but, is there a way to do this somehow?
Typecasting:
char *address;
address=(char*)0x4C00;
> Could I do this using the asm(" command somehow?
No needness for it.
Cheers,
Zeljko Juric