This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH for java/nio buffers
On Fri, Feb 13, 2004 at 08:21:55AM -0800, Per Bothner wrote:
> Michael Koch wrote:
>
> >> * java/nio/Buffer.java: Add default constructor.
> >
> >Why is this needed ? Its not in the official API.
> >
> >> * java/nio/ByteBuffer.java: Likewise.
> >
> >Why is this needed ? Its not in the official API.
>
> The official API has an implicit default constructor.
> Our implementation has other non-public constructors, so
> we have to have an explicit default constructor.
>
> An alternative is to replace all the non-standard constructors
> by static "factory" methods and init' metyhods, but that's a
> change I didn't feel like making.
Wouldnt it be enough to make the default constructor package-private ?
Michael