This is the mail archive of the
cygwin
mailing list for the Cygwin project.
<sys/types.h> incorrectly define macro "howmany"
- From: Keith Thompson <keithsthompson at gmail dot com>
- To: cygwin at cygwin dot com
- Cc: Keith Thompson <Keith dot S dot Thompson at gmail dot com>
- Date: Fri, 20 Nov 2015 03:25:14 -0800
- Subject: <sys/types.h> incorrectly define macro "howmany"
- Authentication-results: sourceware.org; auth=none
The header file /usr/include/sys/types.h defines a macro called "howmany".
As a result, this strictly conforming program:
#include <stdio.h>
int howmany(void) {
return 42;
}
int main(void) {
printf("%d\n", howmany());
}
fails to compile with "gcc -std=c11 -pedantic" (or "-std=c99", or "std=c90").
$ uname -a
CYGWIN_NT-10.0 IE11WIN10 2.2.1(0.289/5/3) 2015-08-20 11:42 x86_64 Cygwin
$
--
Keith Thompson <Keith.S.Thompson@gmail.com>
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple