mirror of
https://github.com/danog/ir.git
synced 2024-11-26 20:34:53 +01:00
6f3cc3052c
Remove POW
20 lines
253 B
Plaintext
20 lines
253 B
Plaintext
--TEST--
|
|
002: abs function
|
|
--ARGS--
|
|
--emit-c
|
|
--CODE--
|
|
{
|
|
l_1 = START(l_4);
|
|
double x = PARAM(l_1, "x", 1);
|
|
double ret = ABS(x);
|
|
l_4 = RETURN(l_1, ret);
|
|
}
|
|
--EXPECT--
|
|
double test(double x)
|
|
{
|
|
double d_1 = x;
|
|
double d_2;
|
|
d_2 = fabs(d_1)
|
|
return d_2;
|
|
}
|