diff options
author | ph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15> | 2014-01-17 17:50:51 +0000 |
---|---|---|
committer | ph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15> | 2014-01-17 17:50:51 +0000 |
commit | 510d1837350aee0818106a3c9661ba86b40b66a7 (patch) | |
tree | e8b1db3de3bf3367e9ab6b1e520b4ef08a303dfe /pcretest.c | |
parent | 5fd8da4b6c81a9afd0cc0186644cda8268012e7b (diff) | |
download | pcre-510d1837350aee0818106a3c9661ba86b40b66a7.tar.gz |
Fix bug in tests when 16/32 bits and --enable-bsr-anycrlf are both set. Extend
pcretest to show the \R default.
git-svn-id: svn://vcs.exim.org/pcre/code/trunk@1450 2f5784b3-3f2a-0410-8824-cb99058d5e15
Diffstat (limited to 'pcretest.c')
-rw-r--r-- | pcretest.c | 12 |
1 files changed, 9 insertions, 3 deletions
@@ -2883,8 +2883,8 @@ printf(" -32 use the 32-bit library\n"); #endif printf(" -b show compiled code\n"); printf(" -C show PCRE compile-time options and exit\n"); -printf(" -C arg show a specific compile-time option\n"); -printf(" and exit with its value. The arg can be:\n"); +printf(" -C arg show a specific compile-time option and exit\n"); +printf(" with its value if numeric (else 0). The arg can be:\n"); printf(" linksize internal link size [2, 3, 4]\n"); printf(" pcre8 8 bit library support enabled [0, 1]\n"); printf(" pcre16 16 bit library support enabled [0, 1]\n"); @@ -2892,7 +2892,8 @@ printf(" pcre32 32 bit library support enabled [0, 1]\n"); printf(" utf Unicode Transformation Format supported [0, 1]\n"); printf(" ucp Unicode Properties supported [0, 1]\n"); printf(" jit Just-in-time compiler supported [0, 1]\n"); -printf(" newline Newline type [CR, LF, CRLF, ANYCRLF, ANY, ???]\n"); +printf(" newline Newline type [CR, LF, CRLF, ANYCRLF, ANY]\n"); +printf(" bsr \\R type [ANYCRLF, ANY]\n"); printf(" -d debug: show compiled code and information (-b and -i)\n"); #if !defined NODFA printf(" -dfa force DFA matching for all subjects\n"); @@ -3231,6 +3232,11 @@ while (argc > 1 && argv[op][0] == '-') (void)PCRE_CONFIG(PCRE_CONFIG_NEWLINE, &rc); print_newline_config(rc, TRUE); } + else if (strcmp(argv[op + 1], "bsr") == 0) + { + (void)PCRE_CONFIG(PCRE_CONFIG_BSR, &rc); + printf("%s\n", rc? "ANYCRLF" : "ANY"); + } else if (strcmp(argv[op + 1], "ebcdic") == 0) { #ifdef EBCDIC |