/[pcre]/code/trunk/pcre_internal.h
ViewVC logotype

Diff of /code/trunk/pcre_internal.h

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

revision 391 by ph10, Tue Mar 17 21:16:01 2009 UTC revision 392 by ph10, Tue Mar 17 21:30:30 2009 UTC
# Line 51  functions whose names all begin with "_p Line 51  functions whose names all begin with "_p
51  #define DEBUG  #define DEBUG
52  #endif  #endif
53    
54  /* We do not support both EBCDIC and UTF-8 at the same time. The "configure"  /* We do not support both EBCDIC and UTF-8 at the same time. The "configure"
55  script prevents both being selected, but not everybody uses "configure". */  script prevents both being selected, but not everybody uses "configure". */
56    
57  #if defined EBCDIC && defined SUPPORT_UTF8  #if defined EBCDIC && defined SUPPORT_UTF8
# Line 600  typedef int BOOL; Line 600  typedef int BOOL;
600    
601  /* If PCRE is to support UTF-8 on EBCDIC platforms, we cannot use normal  /* If PCRE is to support UTF-8 on EBCDIC platforms, we cannot use normal
602  character constants like '*' because the compiler would emit their EBCDIC code,  character constants like '*' because the compiler would emit their EBCDIC code,
603  which is different from their ASCII/UTF-8 code. Instead we define macros for  which is different from their ASCII/UTF-8 code. Instead we define macros for
604  the characters so that they always use the ASCII/UTF-8 code when UTF-8 support  the characters so that they always use the ASCII/UTF-8 code when UTF-8 support
605  is enabled. When UTF-8 support is not enabled, the definitions use character  is enabled. When UTF-8 support is not enabled, the definitions use character
606  literals. Both character and string versions of each character are needed, and  literals. Both character and string versions of each character are needed, and
607  there are some longer strings as well.  there are some longer strings as well.
608    
609  This means that, on EBCDIC platforms, the PCRE library can handle either  This means that, on EBCDIC platforms, the PCRE library can handle either
610  EBCDIC, or UTF-8, but not both. To support both in the same compiled library  EBCDIC, or UTF-8, but not both. To support both in the same compiled library
611  would need different lookups depending on whether PCRE_UTF8 was set or not.  would need different lookups depending on whether PCRE_UTF8 was set or not.
612  This would make it impossible to use characters in switch/case statements,  This would make it impossible to use characters in switch/case statements,
613  which would reduce performance. For a theoretical use (which nobody has asked  which would reduce performance. For a theoretical use (which nobody has asked
614  for) in a minority area (EBCDIC platforms), this is not sensible. Any  for) in a minority area (EBCDIC platforms), this is not sensible. Any
615  application that did need both could compile two versions of the library, using  application that did need both could compile two versions of the library, using
616  macros to give the functions distinct names. */  macros to give the functions distinct names. */
617    
618  #ifndef SUPPORT_UTF8  #ifndef SUPPORT_UTF8

Legend:
Removed from v.391  
changed lines
  Added in v.392

webmaster@exim.org
ViewVC Help
Powered by ViewVC 1.1.12