Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6)

Side by Side Diff: src/third_party/jscre/pcre_tables.cpp

Issue 12511: Added the v8::jscre namespace around the jscre functions to avoid link errors... (Closed) Base URL: http://v8.googlecode.com/svn/trunk/
Patch Set: Created 12 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/third_party/jscre/pcre_internal.h ('k') | src/third_party/jscre/pcre_ucp_searchfuncs.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* This is JavaScriptCore's variant of the PCRE library. While this library 1 /* This is JavaScriptCore's variant of the PCRE library. While this library
2 started out as a copy of PCRE, many of the features of PCRE have been 2 started out as a copy of PCRE, many of the features of PCRE have been
3 removed. This library now supports only the regular expression features 3 removed. This library now supports only the regular expression features
4 required by the JavaScript language specification, and has only the functions 4 required by the JavaScript language specification, and has only the functions
5 needed by JavaScriptCore and the rest of WebKit. 5 needed by JavaScriptCore and the rest of WebKit.
6 6
7 Originally written by Philip Hazel 7 Originally written by Philip Hazel
8 Copyright (c) 1997-2006 University of Cambridge 8 Copyright (c) 1997-2006 University of Cambridge
9 Copyright (C) 2002, 2004, 2006, 2007 Apple Inc. All rights reserved. 9 Copyright (C) 2002, 2004, 2006, 2007 Apple Inc. All rights reserved.
10 10
(...skipping 24 matching lines...) Expand all
35 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 35 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
36 POSSIBILITY OF SUCH DAMAGE. 36 POSSIBILITY OF SUCH DAMAGE.
37 ----------------------------------------------------------------------------- 37 -----------------------------------------------------------------------------
38 */ 38 */
39 39
40 /* This module contains some fixed tables that are used by more than one of the 40 /* This module contains some fixed tables that are used by more than one of the
41 PCRE code modules. */ 41 PCRE code modules. */
42 42
43 #include "pcre_internal.h" 43 #include "pcre_internal.h"
44 44
45 namespace v8 { namespace jscre {
46
45 /************************************************* 47 /*************************************************
46 * Tables for UTF-8 support * 48 * Tables for UTF-8 support *
47 *************************************************/ 49 *************************************************/
48 50
49 /* These are the breakpoints for different numbers of bytes in a UTF-8 51 /* These are the breakpoints for different numbers of bytes in a UTF-8
50 character. */ 52 character. */
51 53
52 const int kjs_pcre_utf8_table1[6] = 54 const int kjs_pcre_utf8_table1[6] =
53 { 0x7f, 0x7ff, 0xffff, 0x1fffff, 0x3ffffff, 0x7fffffff}; 55 { 0x7f, 0x7ff, 0xffff, 0x1fffff, 0x3ffffff, 0x7fffffff};
54 56
55 /* These are the indicator bits and the mask for the data bits to set in the 57 /* These are the indicator bits and the mask for the data bits to set in the
56 first byte of a character, indexed by the number of additional bytes. */ 58 first byte of a character, indexed by the number of additional bytes. */
57 59
58 const int kjs_pcre_utf8_table2[6] = { 0, 0xc0, 0xe0, 0xf0, 0xf8, 0xfc}; 60 const int kjs_pcre_utf8_table2[6] = { 0, 0xc0, 0xe0, 0xf0, 0xf8, 0xfc};
59 const int kjs_pcre_utf8_table3[6] = { 0xff, 0x1f, 0x0f, 0x07, 0x03, 0x01}; 61 const int kjs_pcre_utf8_table3[6] = { 0xff, 0x1f, 0x0f, 0x07, 0x03, 0x01};
60 62
61 /* Table of the number of extra characters, indexed by the first character 63 /* Table of the number of extra characters, indexed by the first character
62 masked with 0x3f. The highest number for a valid UTF-8 character is in fact 64 masked with 0x3f. The highest number for a valid UTF-8 character is in fact
63 0x3d. */ 65 0x3d. */
64 66
65 const unsigned char kjs_pcre_utf8_table4[0x40] = { 67 const unsigned char kjs_pcre_utf8_table4[0x40] = {
66 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, 68 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
67 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, 69 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
68 2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2, 70 2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
69 3,3,3,3,3,3,3,3,4,4,4,4,5,5,5,5 }; 71 3,3,3,3,3,3,3,3,4,4,4,4,5,5,5,5 };
70 72
71 #include "pcre_chartables.c" 73 #include "pcre_chartables.c"
74
75 } } // namespace v8::jscre
OLDNEW
« no previous file with comments | « src/third_party/jscre/pcre_internal.h ('k') | src/third_party/jscre/pcre_ucp_searchfuncs.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698