]> git.ipfire.org Git - thirdparty/gcc.git/commit - gcc/fortran/gfortran.h
re PR fortran/31304 (REPEAT argument NCOPIES is not converted as it should)
authorFrancois-Xavier Coudert <fxcoudert@gcc.gnu.org>
Tue, 3 Apr 2007 21:05:14 +0000 (21:05 +0000)
committerFrançois-Xavier Coudert <fxcoudert@gcc.gnu.org>
Tue, 3 Apr 2007 21:05:14 +0000 (21:05 +0000)
commitf1412ca58a77159d46432eae4eb56ea9edf432b4
tree6af7d5c4118c4c4b7db6fce6a67c9a5054967ba7
parentff2ea58742c65bfe2e779b6e8085a9b387724597
re PR fortran/31304 (REPEAT argument NCOPIES is not converted as it should)

PR fortran/31304

* fortran/gfortran.h (gfc_charlen_int_kind): New prototype.
* fortran/trans-types.c (gfc_charlen_int_kind): New variable.
(gfc_init_types): Define gfc_charlen_int_kind.
* fortran/trans.h (gfor_fndecl_string_repeat): Remove prototype.
* fortran/trans-decl.c (gfor_fndecl_string_repeat): Delete.
(gfc_build_intrinsic_function_decls): Don't set
gfor_fndecl_string_repeat.
* fortran/trans-intrinsic.c (gfc_conv_intrinsic_repeat): Rewrite
so that we don't have to call a library function.
* fortran/simplify.c (gfc_simplify_repeat): Perform the necessary
checks on the NCOPIES argument, and work with arbitrary size
arguments.

* intrinsics/string_intrinsics.c (string_repeat): Remove.

* gfortran.dg/repeat_2.f90: New test.
* gfortran.dg/repeat_3.f90: New test.
* gfortran.dg/repeat_4.f90: New test.

From-SVN: r123481
13 files changed:
gcc/fortran/ChangeLog
gcc/fortran/gfortran.h
gcc/fortran/simplify.c
gcc/fortran/trans-decl.c
gcc/fortran/trans-intrinsic.c
gcc/fortran/trans-types.c
gcc/fortran/trans.h
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/repeat_2.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/repeat_3.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/repeat_4.f90 [new file with mode: 0644]
libgfortran/ChangeLog
libgfortran/intrinsics/string_intrinsics.c