Print this page
remove support for non-ANSI compilation

Split Close
Expand all
Collapse all
          --- old/usr/src/head/iso/string_iso.h
          +++ new/usr/src/head/iso/string_iso.h
↓ open down ↓ 16 lines elided ↑ open up ↑
  17   17   * fields enclosed by brackets "[]" replaced with your own identifying
  18   18   * information: Portions Copyright [yyyy] [name of copyright owner]
  19   19   *
  20   20   * CDDL HEADER END
  21   21   */
  22   22  /*      Copyright (c) 1988 AT&T */
  23   23  /*        All Rights Reserved   */
  24   24  
  25   25  
  26   26  /*
       27 + * Copyright 2014 Garrett D'Amore <garrett@damore.org>
       28 + *
  27   29   * Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
  28   30   * Use is subject to license terms.
  29   31   */
  30   32  
  31   33  /*
  32   34   * An application should not include this header directly.  Instead it
  33   35   * should be included only through the inclusion of other Sun headers.
  34   36   *
  35   37   * The contents of this header is limited to identifiers specified in the
  36   38   * C Standard.  Any new identifiers specified in future amendments to the
  37   39   * C Standard must be placed in this header.  If these new identifiers
  38   40   * are required to also be in the C++ Standard "std" namespace, then for
  39   41   * anything other than macro definitions, corresponding "using" directives
  40   42   * must also be added to <string.h>.
  41   43   */
  42   44  
  43   45  #ifndef _ISO_STRING_ISO_H
  44   46  #define _ISO_STRING_ISO_H
  45   47  
  46      -#pragma ident   "%Z%%M% %I%     %E% SMI"
  47      -
  48   48  #include <sys/feature_tests.h>
  49   49  
  50   50  #ifdef  __cplusplus
  51   51  extern "C" {
  52   52  #endif
  53   53  
  54   54  #if __cplusplus >= 199711L
  55   55  namespace std {
  56   56  #endif
  57   57  
↓ open down ↓ 7 lines elided ↑ open up ↑
  65   65  #endif  /* !_SIZE_T */
  66   66  
  67   67  #ifndef NULL
  68   68  #if defined(_LP64)
  69   69  #define NULL    0L
  70   70  #else
  71   71  #define NULL    0
  72   72  #endif
  73   73  #endif
  74   74  
  75      -#if defined(__STDC__)
  76      -
  77   75  extern int memcmp(const void *, const void *, size_t);
  78   76  extern void *memcpy(void *_RESTRICT_KYWD, const void *_RESTRICT_KYWD, size_t);
  79   77  extern void *memmove(void *, const void *, size_t);
  80   78  extern void *memset(void *, int, size_t);
  81   79  extern char *strcat(char *_RESTRICT_KYWD, const char *_RESTRICT_KYWD);
  82   80  extern int strcmp(const char *, const char *);
  83   81  extern char *strcpy(char *_RESTRICT_KYWD, const char *_RESTRICT_KYWD);
  84   82  extern int strcoll(const char *, const char *);
  85   83  extern size_t strcspn(const char *, const char *);
  86   84  extern char *strerror(int);
↓ open down ↓ 57 lines elided ↑ open up ↑
 144  142  }
 145  143  #endif  /* _STRSTR_INLINE */
 146  144  #else /* __cplusplus >= 199711L */
 147  145  extern void *memchr(const void *, int, size_t);
 148  146  extern char *strchr(const char *, int);
 149  147  extern char *strpbrk(const char *, const char *);
 150  148  extern char *strrchr(const char *, int);
 151  149  extern char *strstr(const char *, const char *);
 152  150  #endif /* __cplusplus >= 199711L */
 153  151  
 154      -#else   /* __STDC__ */
 155      -
 156      -extern void *memchr();
 157      -extern int memcmp();
 158      -extern void *memcpy();
 159      -extern void *memmove();
 160      -extern void *memset();
 161      -extern char *strcat();
 162      -extern char *strchr();
 163      -extern int strcmp();
 164      -extern int strcoll();
 165      -extern char *strcpy();
 166      -extern size_t strcspn();
 167      -extern char *strerror();
 168      -extern size_t strlen();
 169      -extern char *strncat();
 170      -extern int strncmp();
 171      -extern char *strncpy();
 172      -extern char *strpbrk();
 173      -extern char *strrchr();
 174      -extern size_t strspn();
 175      -extern char *strstr();
 176      -extern char *strtok();
 177      -extern size_t strxfrm();
 178      -
 179      -#endif  /* __STDC__ */
 180      -
 181  152  #if __cplusplus >= 199711L
 182  153  }
 183  154  #endif /* end of namespace std */
 184  155  
 185  156  #ifdef  __cplusplus
 186  157  }
 187  158  #endif
 188  159  
 189  160  #endif  /* _ISO_STRING_ISO_H */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX