arith.c (gfc_arith_power): Complex number raised to 0 power is 1.

2004-05-17  Steve Kargl  <kargls@comcast.net>

* arith.c (gfc_arith_power): Complex number raised to 0 power is 1.

From-SVN: r81959
This commit is contained in:
Steve Kargl 2004-05-17 23:54:09 +00:00 committed by Tobias Schlüter
parent 2f70118592
commit f12f786b86
2 changed files with 5 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2004-05-17 Steve Kargl <kargls@comcast.net>
* arith.c (gfc_arith_power): Complex number raised to 0 power is 1.
2004-05-17 Steve Kargl <kargls@comcast.net>
* arith.c (gfc_real2complex): Range checking wrong part of complex

View File

@ -1584,7 +1584,7 @@ gfc_arith_power (gfc_expr * op1, gfc_expr * op2, gfc_expr ** resultp)
else
{
mpf_set_ui (result->value.complex.r, 1);
mpf_set_ui (result->value.complex.r, 0);
mpf_set_ui (result->value.complex.i, 0);
}
break;