]> git.ipfire.org Git - thirdparty/gcc.git/commit
2018-11-18 Thomas Koenig <tkoenig@gcc.gnu.org>
authortkoenig <tkoenig@138bc75d-0d04-0410-961f-82ee72b054a4>
Sun, 18 Nov 2018 09:16:19 +0000 (09:16 +0000)
committertkoenig <tkoenig@138bc75d-0d04-0410-961f-82ee72b054a4>
Sun, 18 Nov 2018 09:16:19 +0000 (09:16 +0000)
commit14103d9067b5cac535f6b797c71d284f35cb7c7b
tree733da04272d4bc40f47098cfc29208db9487f595
parenta9992512f9d756b2f9bc9aafcd80ca753155df7c
2018-11-18  Thomas Koenig  <tkoenig@gcc.gnu.org>

    PR fortran/70260
    * expr.c (gfc_check_assign): Reject assigning to an external
    symbol.
    (gfc_check_pointer_assign): Add suppress_type_test
    argument. Insert line after if. A non-proc pointer can not point
    to a constant.  Only check types if suppress_type_test is false.
    * gfortran.h (gfc_check_pointer_assign): Add optional
    suppress_type_test argument.
    * resolve.c (gfc_resolve_code):  Move up gfc_check_pointer_assign
    and give it the extra argument.
    (resolve_fl_procedure): Set error on value for a function with
    an inizializer.

2018-11-18  Thomas Koenig  <tkoenig@gcc.gnu.org>

    PR fortran/70260
    * gfortran.dg/proc_ptr_result_5.f90:  Add dg-error directive.
    * gfortran.dg/protected_4.f90: Split line to allow for extra error.
    * gfortran.dg/protected_6.f90: Likewise.
    * gfortran.dg/assign_11.f90: New test.
    * gfortran.dg/pointer_assign_12.f90: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@266248 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/fortran/ChangeLog
gcc/fortran/expr.c
gcc/fortran/gfortran.h
gcc/fortran/resolve.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/assign_11.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/pointer_assign_12.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/proc_ptr_result_5.f90
gcc/testsuite/gfortran.dg/protected_4.f90
gcc/testsuite/gfortran.dg/protected_6.f90