view run/c/cfloat_11_A.d @ 1237:23b89cbbe105

[Issue 575] New: wrong evaluation of (creal * 2 + 1i) Thomas K?hne <thomas-doop@kuehne.cn> 2006-11-19 news:bug-575-31@http.d.puremagic.com/issues/
author thomask
date Sat, 25 Nov 2006 17:52:58 +0000
parents
children e6887749b811
line wrap: on
line source

// $HeadURL$
// $Date$
// $Author$

// @author@	Thomas Kühne <thomas-doop@kuehne.cn>
// @date@	2006-11-19
// @uri@	news:bug-575-31@http.d.puremagic.com/issues/
// @desc@	[Issue 575] New: wrong evaluation of (creal * 2 + 1i)

module dstress.run.c.cfloat_11_A;

cfloat foo(cfloat a){
	return a * 2.0f + 1.0fi;
}

int main(){
	if(foo(1.0f + 2.0fi) != 2.0f + 5.0fi){
		assert(0);
	}
	return 0;
}