Print this page
3853 __cplusplus change and headers incompatipility with clang

Split Close
Expand all
Collapse all
          --- old/usr/src/head/unistd.h
          +++ new/usr/src/head/unistd.h
↓ open down ↓ 453 lines elided ↑ open up ↑
 454  454          const char *, int *, int);
 455  455  #endif
 456  456  extern ssize_t read(int, void *, size_t);
 457  457  #if !defined(__XOPEN_OR_POSIX) || \
 458  458          defined(_XPG4_2) || defined(__EXTENSIONS__)
 459  459  extern ssize_t readlink(const char *_RESTRICT_KYWD, char *_RESTRICT_KYWD,
 460  460          size_t);
 461  461  #endif
 462  462  #if (!defined(__XOPEN_OR_POSIX) || (defined(_XPG3) && !defined(_XPG4))) || \
 463  463          defined(__EXTENSIONS__)
      464 +#if __cplusplus >= 199711L
      465 +namespace std {
      466 +#endif
 464  467  extern int rename(const char *, const char *);
      468 +#if __cplusplus >= 199711L
      469 +} /* end of namespace std */
      470 +
      471 +using std::rename;
      472 +#endif /* __cplusplus >= 199711L */
 465  473  #endif /* (!defined(__XOPEN_OR_POSIX) || (defined(_XPG3)... */
 466  474  #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__)
 467  475  extern int resolvepath(const char *, char *, size_t);
 468  476  /* per RFC 3542; This is also defined in netdb.h */
 469  477  extern int rexec_af(char **, unsigned short, const char *, const char *,
 470  478          const char *, int *, int);
 471  479  #endif /* !defined(__XOPEN_OR_POSIX)|| defined(__EXTENSIONS__) */
 472  480  extern int rmdir(const char *);
 473  481  #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__)
 474  482  /* per RFC 3542; This is also defined in netdb.h */
↓ open down ↓ 552 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX