aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/arith.c
diff options
context:
space:
mode:
authorSteve Kargl <kargls@comcast.net>2004-05-17 23:19:47 +0000
committerTobias Schlüter <tobi@gcc.gnu.org>2004-05-18 01:19:47 +0200
commite876acbd25c26828c235f0723fc5b4554f4ea9d6 (patch)
treea1867ab59ef9120ab930202aa1003d1ace7e95e9 /gcc/fortran/arith.c
parentb2342b5484b0e968f4a10f58025935df13b23941 (diff)
downloadgcc-e876acbd25c26828c235f0723fc5b4554f4ea9d6.zip
gcc-e876acbd25c26828c235f0723fc5b4554f4ea9d6.tar.gz
gcc-e876acbd25c26828c235f0723fc5b4554f4ea9d6.tar.bz2
arith.c (gfc_real2complex): Range checking wrong part of complex number.
2004-05-17 Steve Kargl <kargls@comcast.net> * arith.c (gfc_real2complex): Range checking wrong part of complex number. From-SVN: r81957
Diffstat (limited to 'gcc/fortran/arith.c')
-rw-r--r--gcc/fortran/arith.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/fortran/arith.c b/gcc/fortran/arith.c
index 7d47151..5b4d701 100644
--- a/gcc/fortran/arith.c
+++ b/gcc/fortran/arith.c
@@ -2666,7 +2666,7 @@ gfc_real2complex (gfc_expr * src, int kind)
mpf_set (result->value.complex.r, src->value.real);
mpf_set_ui (result->value.complex.i, 0);
- if ((rc = gfc_check_real_range (result->value.complex.i, kind)) != ARITH_OK)
+ if ((rc = gfc_check_real_range (result->value.complex.r, kind)) != ARITH_OK)
{
arith_error (rc, &src->ts, &result->ts, &src->where);
gfc_free_expr (result);