This is the mail archive of the gcc-patches@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]

Re: [arm] Make constructors return this


Paul Brook writes:
 > On Friday 02 July 2004 22:01, Mark Mitchell wrote:
 > > Paul Brook wrote:
 > > >The patch below makes full and subobject constructors and destructors
 > > > return the object constructed or destroyed, as required by the ARM EABI.
 > > > It doesn't yet attempt to use this information.
 > <snip>
 > > >+      /* We can't use the proper return type here because we run into
 > > >+	 problems with abiguous bases and covariant returns.  */
 > > >+      if (targetm.cxx.cdtor_returns_this () && !TYPE_FOR_JAVA (optype))
 > >
 > > Why not do this in the TYPE_FOR_JAVA case as well?
 > 
 > Two reasons:
 > - (void *) isn't a valid java type.
 > - It would change the Java ABI, requiring corresponding changes to gcj and 
 > other JVMs.

Why would it?  If the library doesn't use the return value, which
would anything need to change?

Andrew.


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