public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libobjc/50428] New: Consider changing semantics of +initialize so that it is inherited
@ 2011-09-16  8:21 nicola at gcc dot gnu.org
  2011-09-16  8:34 ` [Bug libobjc/50428] " nicola at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: nicola at gcc dot gnu.org @ 2011-09-16  8:21 UTC (permalink / raw)
  To: gcc-bugs

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

             Bug #: 50428
           Summary: Consider changing semantics of +initialize so that it
                    is inherited
    Classification: Unclassified
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: libobjc
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: nicola@gcc.gnu.org


One of the remaining differences between the GNU Objective-C runtime and the
Apple one is that +initialize methods are inherited in the Apple runtime but
not in the GNU one.

To reduce differences, we could change the GNU runtime to inherit them too. 
This
is a change in behaviour and should be clearly advertised in the release notes.

Thanks


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libobjc/50428] Consider changing semantics of +initialize so that it is inherited
  2011-09-16  8:21 [Bug libobjc/50428] New: Consider changing semantics of +initialize so that it is inherited nicola at gcc dot gnu.org
@ 2011-09-16  8:34 ` nicola at gcc dot gnu.org
  2011-10-08 17:52 ` nicola at gcc dot gnu.org
  2011-10-08 17:56 ` nicola at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: nicola at gcc dot gnu.org @ 2011-09-16  8:34 UTC (permalink / raw)
  To: gcc-bugs

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

Nicola Pero <nicola at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2011-09-16
     Ever Confirmed|0                           |1

--- Comment #1 from Nicola Pero <nicola at gcc dot gnu.org> 2011-09-16 08:04:13 UTC ---
We should also document +initialize in the GCC Manual, no matter if we keep the
existing semantics or change them.

Thanks


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libobjc/50428] Consider changing semantics of +initialize so that it is inherited
  2011-09-16  8:21 [Bug libobjc/50428] New: Consider changing semantics of +initialize so that it is inherited nicola at gcc dot gnu.org
  2011-09-16  8:34 ` [Bug libobjc/50428] " nicola at gcc dot gnu.org
@ 2011-10-08 17:52 ` nicola at gcc dot gnu.org
  2011-10-08 17:56 ` nicola at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: nicola at gcc dot gnu.org @ 2011-10-08 17:52 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Nicola Pero <nicola at gcc dot gnu.org> 2011-10-08 17:52:11 UTC ---
Author: nicola
Date: Sat Oct  8 17:52:06 2011
New Revision: 179711

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=179711
Log:
In libobjc/:
2011-10-08  Richard Frith-Macdonald <rfm@gnu.org>
            Nicola Pero  <nicola.pero@meta-innovation.com>

    PR libobjc/50428
    * sendmsg.c (__objc_send_initialize): If a class does not have an
    +initialize method, search for an +initialize method in the
    superclass and in the ancestor classes and execute the first one
    that is found.  This makes the GNU runtime behave in the same way
    as the Apple/NeXT runtime with respect to +initialize methods and
    subclassing.

In gcc/:
2011-10-08  Nicola Pero  <nicola.pero@meta-innovation.com>

    PR libobjc/50428
    * doc/objc.texi (Garbage Collection): Updated example to protect
    +initialize against execution in subclasses.

In gcc/testsuite/:
2011-10-08  Nicola Pero  <nicola.pero@meta-innovation.com>

    PR libobjc/50428    
    * objc/execute/initialize-1.m: New test.

Added:
    trunk/gcc/testsuite/objc/execute/initialize-1.m
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/doc/objc.texi
    trunk/gcc/testsuite/ChangeLog
    trunk/libobjc/ChangeLog
    trunk/libobjc/sendmsg.c


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libobjc/50428] Consider changing semantics of +initialize so that it is inherited
  2011-09-16  8:21 [Bug libobjc/50428] New: Consider changing semantics of +initialize so that it is inherited nicola at gcc dot gnu.org
  2011-09-16  8:34 ` [Bug libobjc/50428] " nicola at gcc dot gnu.org
  2011-10-08 17:52 ` nicola at gcc dot gnu.org
@ 2011-10-08 17:56 ` nicola at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: nicola at gcc dot gnu.org @ 2011-10-08 17:56 UTC (permalink / raw)
  To: gcc-bugs

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

Nicola Pero <nicola at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED

--- Comment #3 from Nicola Pero <nicola at gcc dot gnu.org> 2011-10-08 17:56:09 UTC ---
Implemented in trunk.  The change will appear in 4.7.0.

Thanks


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-10-08 17:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-16  8:21 [Bug libobjc/50428] New: Consider changing semantics of +initialize so that it is inherited nicola at gcc dot gnu.org
2011-09-16  8:34 ` [Bug libobjc/50428] " nicola at gcc dot gnu.org
2011-10-08 17:52 ` nicola at gcc dot gnu.org
2011-10-08 17:56 ` nicola at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).