Web lists-archives.com

Re: [Mingw-users] _XOPEN_SOURCE




-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 23/04/17 18:15, Bryan Henderson wrote:
>> bar.c:2:19: error: operator '&&' has no left operand
> 
> I wonder how you get that.  I was unable to reproduce it.

Simply, by reproducing the example guard from feature_test_macros(7):

  $ cat foo.c
  #define _XOPEN_SOURCE
  #if defined __BSD_SOURCE || (_XOPEN_SOURCE && _XOPEN_SOURCE < 500)
  #endif

  $ gcc --version
  gcc (Debian 4.8.2-1) 4.8.2
  Copyright (C) 2013 Free Software Foundation, Inc.
  This is free software; see the source for copying conditions.
  There is NO warranty; not even for MERCHANTABILITY or FITNESS
  FOR A PARTICULAR PURPOSE.

  $ gcc -c -fsyntax-only foo.c
  foo.c:2:44: error: operator '&&' has no left operand
   #if defined __BSD_SOURCE || (_XOPEN_SOURCE && _XOPEN_SOURCE < 500)
                                            ^

  $ mingw32-gcc --version
  mingw32-gcc (GCC) 5.3.0
  Copyright (C) 2015 Free Software Foundation, Inc.
  This is free software; see the source for copying conditions.
  There is NO warranty; not even for MERCHANTABILITY or FITNESS
  FOR A PARTICULAR PURPOSE.

  $ mingw32-gcc -c -fsyntax-only foo.c
  foo.c:2:44: error: operator '&&' has no left operand
   #if defined __BSD_SOURCE || (_XOPEN_SOURCE && _XOPEN_SOURCE < 500)
                                            ^

- -- 
Regards,
Keith.

Public key available from keys.gnupg.net
Key fingerprint: C19E C018 1547 DE50 E1D4 8F53 C0AD 36C6 347E 5A3F
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (GNU/Linux)

iQIcBAEBAgAGBQJY/QmSAAoJEMCtNsY0flo/BpYP/1W1QS+zYjI1z/bdHdZDEsp4
+PRb+DPPDUonvYpCOJum/eEg41IfydbqR8w7wxqI5OnbnzpdEPygSdf36GMvGCbe
F9CsPZVj6TAz/kEeKh9PI4lIk2sZdnJq7JrDQdO502SScGiUApefWZVMI1mIFPZ3
Czz1Ph92G8X5xOj5SKpUpbpUF3GA1/rOzKFW3VDUIm/9P1H7WyvbI5TDd8l8ilmx
ccl1BnIRtoAzqnUbJwwamUWgAtqx6u3isy7yh9QrXB2e6CIhdqH4O8DftRN4Scyv
vP8CioqZGWkliEGjzzY7/S2/tx/kntMyyLtQzIJWtqC2PMGszeehTdKfV1kGIv4u
KfJxOrH5qpU0cSuLMfTEusnXNjGdDu9vjw3fYJ/3nJPiO5gxWl5nFYKi+PK9dm0c
/xnE7bLLjwVROGvry36ZnTTnJ7RHj4aXpWELEKfChkB6xvChmSR7m+7TQ1Ytnfgt
isL7NUOZN/YWwU7JDqoalnOiSak7kBAr0OkJtagpIrMFbq/e+XjEDwg4mlm+aoEF
WX09ZnHWkB1qHC6kpYPJVwAMAtQ/UqABJDxV9RZUmzvmpWlO5m4vn/9xQ6+oGWRt
8turuK0ZfsLPIWYHUVg10plMRKOADKTYYSpSd7JQv5fWZaNG7hb7loX/+IRHhoqP
QboKFWLVxB93SZGPJqDW
=YpyE
-----END PGP SIGNATURE-----

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
MinGW-users mailing list
MinGW-users@xxxxxxxxxxxxxxxxxxxxx

This list observes the Etiquette found at 
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users
Also: mailto:mingw-users-request@xxxxxxxxxxxxxxxxxxxxx?subject=unsubscribe