Date: Mon, 19 Jun 2000 20:17:48 +0300 (IDT) From: Eli Zaretskii X-Sender: eliz AT is To: Laurynas Biveinis cc: DJGPP Workers Subject: Re: Patch: new GCC builtins for stdarg.h/varargs.h In-Reply-To: <394E3ECE.8D7A4DD7@softhome.net> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Mon, 19 Jun 2000, Laurynas Biveinis wrote: > Eli Zaretskii wrote: > > va_copy was invented by C99, right? And GCC didn't support C99 before > > v2.96, right? > > Not exactly. GCC 2.96 isn't the key version when talking about C99. We were talking about va_copy, not C99 in general, as far as its support in GCC goes. It is true that va_copy is supported by GCC builtins in 2.96 only, is it? > > So there's nothing wrong if we don't support va_copy with > > versions of GCC before 2.96. > > Currently there's nothing wrong. But when we start adding C99 > features, it will become wrong. What will become wrong? We don't intend to support C99 features that require compiler support, unless the version of the compiler in use actually does provide that support, do we? Since va_copy requires a special feature of the compiler, we can require that the compiler be new enough, for va_copy to be supported. People who use older compilers won't have va_copy, just like they don't today. > I still do not understand, why va_copy is binded with GCC 2.96. Because you told that earlier versions don't support a builtin that is required for va_copy. > I think I'll just test > trivial non-builtin va_copy implementation, if it works - > it would be the best way to end discussion ;) If you can run the trivial implementation via some test suite that proves that it indeed works, then I agree. Perhaps it might be a good idea to ask the GCC maintainers whether your trivial implementation has some pitfalls. > > va_list and va_arg are different: they are in C90, and DJGPP supported > > them from day one. > > The only difference I see is standard version. I should be missing > something here. The point is that introducing a new feature without compiler support is different from continued support for an old feature that is proven to work with old compilers.