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/55057] [OOP] wrong result with abstract type


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55057

Mikael Morin <mikael at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mikael at gcc dot gnu.org

--- Comment #6 from Mikael Morin <mikael at gcc dot gnu.org> ---
(In reply to janus from comment #3)
> Here is a reduced test case, which is not usable as a runtime test, but
> shows the wrong dump:
> 
[...]
> 
> The dump of 'sub2' is wrong in 4.8, while 'sub1' is ok. With 4.7, both are
> wrong.

sub2's dump is now:

sub2 (struct __class_m_T2 & restrict b)
{
  {
    struct __class_m_T1 class.7;

    class.7._data = (struct t1 *) b->_data->work._data.data + (sizetype)
((b->_data->work._data.offset + 1) * (integer(kind=8))
b->_data->work._vptr->_size);
    class.7._vptr = b->_data->work._vptr;
    alt (&class.7);
  }
}

This appears correct to me. At least, it "involves _vptr->_size".
And the output of comment #0 is now:

$ ./comment_0
 All the following values should be 2.0
   2.00000000
   2.00000000
   2.00000000
 All the following values should be 2.0
   2.00000000
   2.00000000
   2.00000000    

FIXED?


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