Mercurial > projects > dstress
changeset 1048:ea0247788622
<sean@f4.ca>
2006-03-05
news:bug-13-3@http.d.puremagic.com/bugzilla/
author | thomask |
---|---|
date | Thu, 29 Jun 2006 13:23:49 +0000 |
parents | 90fb42f640a4 |
children | 32c1be40d218 |
files | run/i/inout_02_A.d |
diffstat | 1 files changed, 38 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/i/inout_02_A.d Thu Jun 29 13:23:49 2006 +0000 @@ -0,0 +1,38 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ <sean@f4.ca> +// @date@ 2006-03-05 +// @uri@ news:bug-13-3@http.d.puremagic.com/bugzilla/ + +module dstress.run.i.inout_02_A; + +version(D_InlineASM_X86){ + version = runTest; +} + +version(runTest){ + void fn(inout byte val){ + asm{ + mov EAX, val; + inc [EAX]; + } + } + + int main(){ + byte b = 3; + fn(b); + + if(b != 4){ + assert(0); + } + + return 0; + } +}else{ + pragma(msg, "DSTRESS{XFAIL}: no inline ASM support"); + static assert(0); +} + +