Setting class variable from inline assembly
Thomas Kuehne
thomas-dloop at kuehne.cn
Sun May 21 12:41:22 PDT 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Thomas Kuehne schrieb am 2006-05-21:
>
> pmoore schrieb am 2006-05-20:
>> Hi,
>>
>> It seems that within inline assembly I can read a class variable but I can't set
>> it. Is this a bug or is there a good reason for this?
> What you are looking for is:
> # void* p = this;
> #
> # asm{
> # mov EBX, p;
> # mov EAX, [EBX+myvar2];
> # // something productive here
> # mov [EBX+myvar2], EBX;
> # }
The last line should have been:
mov [EBX+myvar2], EAX;
Thomas
-----BEGIN PGP SIGNATURE-----
iD8DBQFEcM/F3w+/yD4P9tIRArUYAJ92IWIxHqfnsRYg86NQvRABJhXfrACePP8P
ElcidKuVewNvYMjXQqQoOjo=
=nNmk
-----END PGP SIGNATURE-----
More information about the Digitalmars-d-bugs
mailing list