This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/82312] [7/8 Regression] [OOP] Pointer assignment to component of class variable results wrong vptr for the variable.


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82312

--- Comment #4 from Paul Thomas <pault at gcc dot gnu.org> ---
Author: pault
Date: Sat Oct 21 17:09:43 2017
New Revision: 253976

URL: https://gcc.gnu.org/viewcvs?rev=253976&root=gcc&view=rev
Log:
2017-10-21  Paul Thomas  <pault@gcc.gnu.org>

        PR fortran/82312
        * resolve.c (gfc_resolve_code): Simplify condition for class
        pointer assignments becoming regular assignments by asserting
        that only class valued targets are permitted.
        * trans-expr.c (trans_class_pointer_fcn): New function using a
        block of code from gfc_trans_pointer_assignment.
        (gfc_trans_pointer_assignment): Call the new function. Tidy up
        a minor whitespace issue.

2017-10-21  Paul Thomas  <pault@gcc.gnu.org>

        PR fortran/82312
        * gfortran.dg/typebound_proc_36.f90 : New test.

Added:
    branches/gcc-7-branch/gcc/testsuite/gfortran.dg/typebound_proc_36.f90
Modified:
    branches/gcc-7-branch/gcc/fortran/ChangeLog
    branches/gcc-7-branch/gcc/fortran/resolve.c
    branches/gcc-7-branch/gcc/fortran/trans-expr.c
    branches/gcc-7-branch/gcc/testsuite/ChangeLog

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]