Print this page
remove support for non-ANSI compilation

Split Close
Expand all
Collapse all
          --- old/usr/src/head/strings.h
          +++ new/usr/src/head/strings.h
↓ open down ↓ 12 lines elided ↑ open up ↑
  13   13   *
  14   14   * When distributing Covered Code, include this CDDL HEADER in each
  15   15   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16   16   * If applicable, add the following below this CDDL HEADER, with the
  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  /*
       23 + * Copyright 2014 Garrett D'Amore <garrett@damore.org>
       24 + *
  23   25   * Copyright (c) 1995, 1996, by Sun Microsystems, Inc.
  24   26   * All rights reserved.
  25   27   */
  26      -/*
  27      - * Copyright 2013 Garrett D'Amore <garrett@damore.org>
  28      - */
  29   28  
  30   29  #ifndef _STRINGS_H
  31   30  #define _STRINGS_H
  32   31  
  33   32  #include <sys/types.h>
  34   33  #include <sys/feature_tests.h>
  35   34  
  36   35  #if !defined(_XOPEN_SOURCE) || defined(__EXTENSIONS__)
  37   36  #include <string.h>
  38   37  #endif
  39   38  
  40   39  #ifdef  __cplusplus
  41   40  extern "C" {
  42   41  #endif
  43   42  
  44      -#if defined(__STDC__)
  45      -
  46   43  extern int bcmp(const void *, const void *, size_t);
  47   44  extern void bcopy(const void *, void *, size_t);
  48   45  extern void bzero(void *, size_t);
  49   46  
  50   47  extern char *index(const char *, int);
  51   48  extern char *rindex(const char *, int);
  52   49  
  53   50  /*
  54   51   * X/Open System Interfaces and Headers, Issue 4, Version 2, defines
  55   52   * both <string.h> and <strings.h>.  The namespace requirements
↓ open down ↓ 11 lines elided ↑ open up ↑
  67   64  #if defined(_XPG7)
  68   65  #ifndef _LOCALE_T
  69   66  #define _LOCALE_T
  70   67  typedef struct _locale *locale_t;
  71   68  #endif
  72   69  extern int strcasecmp_l(const char *, const char *, locale_t);
  73   70  extern int strncasecmp_l(const char *, const char *, size_t, locale_t);
  74   71  #endif  /* defined(_XPG7) */
  75   72  #endif  /* defined(_XPG4_2) && !defined(__EXTENSIONS__) */
  76   73  
  77      -#else
  78      -
  79      -extern int bcmp();
  80      -extern void bcopy();
  81      -extern void bzero();
  82      -
  83      -extern char *index();
  84      -extern char *rindex();
  85      -
  86      -#if defined(_XPG4_2) && !defined(__EXTENSIONS__)
  87      -extern int ffs();
  88      -extern int strcasecmp();
  89      -extern int strncasecmp();
  90      -#if defined(_XPG7)
  91      -extern int strcasecmp_l();
  92      -extern int strncasecmp_l();
  93      -#endif
  94      -#endif /* defined(_XPG4_2) && !defined(__EXTENSIONS__) */
  95      -
  96      -#endif  /* __STDC__ */
  97      -
  98   74  #ifdef  __cplusplus
  99   75  }
 100   76  #endif
 101   77  
 102   78  #endif  /* _STRINGS_H */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX