OSDN Git Service

* dependency.c (gfc_dep_compare_expr): Strip parentheses and unary
authorsayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 1 Apr 2006 07:11:35 +0000 (07:11 +0000)
committersayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 1 Apr 2006 07:11:35 +0000 (07:11 +0000)
commit4d4677fd775aada7c8b69f0ad3493a1a901f4c3f
tree819193295047cb2228169bf880780bbaf6997cd3
parent29bf9219c9121cd0c7244c9b954a3137d17ed88d
* dependency.c (gfc_dep_compare_expr): Strip parentheses and unary
plus operators when comparing expressions.  Handle comparisons of
the form "X+C vs. X", "X vs. X+C", "X-C vs. X" and "X vs. X-C" where
C is an integer constant.  Handle comparisons of the form "P+Q vs.
R+S" and "P-Q vs. R-S".  Handle comparisons of integral extensions
specially (increasing functions) so extend(A) > extend(B), when A>B.
(gfc_check_element_vs_element): Move test later, so that we ignore
the fact that "A < B" or "A > B" when A or B contains a forall index.

* gfortran.dg/dependency_14.f90: New test case.
* gfortran.dg/dependency_15.f90: Likewise.
* gfortran.dg/dependency_16.f90: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@112605 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/fortran/ChangeLog
gcc/fortran/dependency.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/dependency_14.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/dependency_15.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/dependency_16.f90 [new file with mode: 0644]