/[pcre]/code/trunk/pcre_globals.c
ViewVC logotype

Diff of /code/trunk/pcre_globals.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 92 by nigel, Sat Feb 24 21:41:21 2007 UTC revision 93 by nigel, Sat Feb 24 21:41:42 2007 UTC
# Line 51  differently, and global variables are no Line 51  differently, and global variables are no
51    
52    
53  #ifndef VPCOMPAT  #ifndef VPCOMPAT
54    
55    /**************************************************************************
56    This code used to be here for use when compiling as a C++ library. However,
57    according to Dair Grant it is not needed: "
58    
59     Including 'extern "C"' in the declaration generates an "initialized and
60     declared `extern'" warning from gcc 4.0.1. Since we include pcre_internal.h,
61     which includes pcre.h, which declares these prototypes within an extern "C" {}
62     block, we shouldn't need the prefix here.
63    
64    So, from Release 7.0 I have cut this out.
65    
66  #ifdef __cplusplus  #ifdef __cplusplus
67  extern "C" void *(*pcre_malloc)(size_t) = malloc;  extern "C" void *(*pcre_malloc)(size_t) = malloc;
68  extern "C" void  (*pcre_free)(void *) = free;  extern "C" void  (*pcre_free)(void *) = free;
# Line 58  extern "C" void *(*pcre_stack_malloc)(si Line 70  extern "C" void *(*pcre_stack_malloc)(si
70  extern "C" void  (*pcre_stack_free)(void *) = free;  extern "C" void  (*pcre_stack_free)(void *) = free;
71  extern "C" int   (*pcre_callout)(pcre_callout_block *) = NULL;  extern "C" int   (*pcre_callout)(pcre_callout_block *) = NULL;
72  #else  #else
73    **************************************************************************/
74    
75  void *(*pcre_malloc)(size_t) = malloc;  void *(*pcre_malloc)(size_t) = malloc;
76  void  (*pcre_free)(void *) = free;  void  (*pcre_free)(void *) = free;
77  void *(*pcre_stack_malloc)(size_t) = malloc;  void *(*pcre_stack_malloc)(size_t) = malloc;
78  void  (*pcre_stack_free)(void *) = free;  void  (*pcre_stack_free)(void *) = free;
79  int   (*pcre_callout)(pcre_callout_block *) = NULL;  int   (*pcre_callout)(pcre_callout_block *) = NULL;
80  #endif  #endif
 #endif  
81    
82  /* End of pcre_globals.c */  /* End of pcre_globals.c */

Legend:
Removed from v.92  
changed lines
  Added in v.93

webmaster@exim.org
ViewVC Help
Powered by ViewVC 1.1.12