www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - Linker warning for va_arg!(char[])

reply Lukas Pinkowski <Lukas.Pinkowski web.de> writes:
For this snippet:

/+
variadic.d
+/
import std.stdarg;

void func( ... )
{
  char[] foo;
  for(uint i=0; i<_arguments.length; i++)
  {
    foo = va_arg!(char[])(_argptr);
  }
}

int main()
{
  return 0;
}

I get the following warning:

/usr/lib/gcc-lib/i586-suse-linux/3.3.1/../../../../i586-suse-linux/bin/ld:
Warning: size of symbol`_D3std6stdarg9va_arg_Aa6va_argFKPvZAa' changed from
23 in variadic.o to 34
in /usr/lib/gcc-lib/i586-suse-linux/3.3.1/../../../libphobos.a(format.o)

Is it a bug in the template instantiation, or is it a bug in SuSE 9.0 ld?

Greetings,

Lukas Pinkowski
Mar 08 2005
parent reply Lukas Pinkowski <Lukas.Pinkowski web.de> writes:
Lukas Pinkowski wrote:
 For this snippet:
 
 /+
 variadic.d
 +/
 import std.stdarg;
 
 void func( ... )
 {
   char[] foo;
   for(uint i=0; i<_arguments.length; i++)
   {
     foo = va_arg!(char[])(_argptr);
   }
 }
 
 int main()
 {
   return 0;
 }
 
 I get the following warning:
 
 /usr/lib/gcc-lib/i586-suse-linux/3.3.1/../../../../i586-suse-linux/bin/ld:
 Warning: size of symbol`_D3std6stdarg9va_arg_Aa6va_argFKPvZAa' changed
 from 23 in variadic.o to 34
 in /usr/lib/gcc-lib/i586-suse-linux/3.3.1/../../../libphobos.a(format.o)
 
 Is it a bug in the template instantiation, or is it a bug in SuSE 9.0 ld?
 
 Greetings,
 
 Lukas Pinkowski
Um, I forgot; I'm using DMD 0.116 on Linux
Mar 08 2005
parent Thomas Kuehne <thomas-dloop kuehne.thisisspam.cn> writes:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Lukas Pinkowski schrieb am Tue, 08 Mar 2005 17:14:56 +0100:
 Lukas Pinkowski wrote:
 For this snippet:
 
 /+
 variadic.d
 +/
 import std.stdarg;
 
 void func( ... )
 {
   char[] foo;
   for(uint i=0; i<_arguments.length; i++)
   {
     foo = va_arg!(char[])(_argptr);
   }
 }
 
 int main()
 {
   return 0;
 }
 
 I get the following warning:
 
 /usr/lib/gcc-lib/i586-suse-linux/3.3.1/../../../../i586-suse-linux/bin/ld:
 Warning: size of symbol`_D3std6stdarg9va_arg_Aa6va_argFKPvZAa' changed
 from 23 in variadic.o to 34
 in /usr/lib/gcc-lib/i586-suse-linux/3.3.1/../../../libphobos.a(format.o)
 I forgot; I'm using DMD 0.116 on Linux
A browny for anyone downsizeing this(stdarg.d, format.d, variadic.d). Thomas -----BEGIN PGP SIGNATURE----- iD8DBQFCOG3Y3w+/yD4P9tIRAr8vAJ40Qs9PQvG76+C23HQgY0CjYxuGtgCgjPpD I7ARDvJnIHFg5wTBjKvGGGA= =lsZw -----END PGP SIGNATURE-----
Mar 16 2005