This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/26921] long long bit fields are passed to variadic functions as longs
- From: "bugzilla at hburch dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 29 Mar 2006 14:59:25 -0000
- Subject: [Bug c/26921] long long bit fields are passed to variadic functions as longs
- References: <bug-26921-12437@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #3 from bugzilla at hburch dot com 2006-03-29 14:59 -------
#include <stdio.h>
struct s {
long long int a : 33;
};
struct s foo = {0};
int main(void) {
printf ("%lld\n", foo.a);
return 0;
}
produces the following output using "gcc -Wall -o a a.c" for same system as Mac
OS X Bundle (gcc 4.0.0):
gcc -Wall -o a a.c
a.c: In function 'main':
a.c:10: warning: format '%lld' expects type 'long long int', but argument 2 has
type 'long long int'
Attached here because almost assuredly related.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26921