Changes between Initial Version and Version 1 of Ticket #61145, comment 6
- Timestamp:
- Sep 9, 2020, 1:26:00 AM (4 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #61145, comment 6
initial v1 1 1 No I think it's correct. Setting _XOPEN_SOURCE to 500 is equivalent to setting _POSIX_C_SOURCE to 199506, and strdup was only added to POSIX in POSIX.1-2001. Before that, strdup was an X/Open extension, and you had to define _XOPEN_SOURCE_EXTENDED to use it on systems that implemented those extensions. Understandably, Apple only implements the POSIX requirements and _XOPEN_SOURCE_EXTENDED does nothing on current macOS. 2 2 3 I would assume p ervious versions of clang were letting the implicit declaration through with a warning.3 I would assume previous versions of clang were letting the implicit declaration through with a warning.