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

Side by Side Diff: src/regexp/regexp-utils.h

Issue 2415383002: [regexp] Match spec semantics in AdvanceStringIndex (Closed)
Patch Set: Created 4 years, 2 months 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
« no previous file with comments | « src/builtins/builtins-regexp.cc ('k') | src/regexp/regexp-utils.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_REGEXP_REGEXP_UTILS_H_ 5 #ifndef V8_REGEXP_REGEXP_UTILS_H_
6 #define V8_REGEXP_REGEXP_UTILS_H_ 6 #define V8_REGEXP_REGEXP_UTILS_H_
7 7
8 #include "src/objects.h" 8 #include "src/objects.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 Handle<String> string, 43 Handle<String> string,
44 Handle<Object> exec); 44 Handle<Object> exec);
45 45
46 // ES#sec-isregexp IsRegExp ( argument ) 46 // ES#sec-isregexp IsRegExp ( argument )
47 // Includes checking of the match property. 47 // Includes checking of the match property.
48 static Maybe<bool> IsRegExp(Isolate* isolate, Handle<Object> object); 48 static Maybe<bool> IsRegExp(Isolate* isolate, Handle<Object> object);
49 49
50 // Checks whether exec is identical to the initial RegExp.prototype.exec. 50 // Checks whether exec is identical to the initial RegExp.prototype.exec.
51 static bool IsBuiltinExec(Handle<Object> exec); 51 static bool IsBuiltinExec(Handle<Object> exec);
52 52
53 // Generic index increment methods respecting unicode surrogate pairs. 53 // ES#sec-advancestringindex
54 // AdvanceStringIndex ( S, index, unicode )
54 static int AdvanceStringIndex(Isolate* isolate, Handle<String> string, 55 static int AdvanceStringIndex(Isolate* isolate, Handle<String> string,
55 int index, bool unicode); 56 int index, bool unicode);
56 static MaybeHandle<Object> SetAdvancedStringIndex(Isolate* isolate, 57 static MaybeHandle<Object> SetAdvancedStringIndex(Isolate* isolate,
57 Handle<JSReceiver> regexp, 58 Handle<JSReceiver> regexp,
58 Handle<String> string, 59 Handle<String> string,
59 bool unicode); 60 bool unicode);
60 }; 61 };
61 62
62 } // namespace internal 63 } // namespace internal
63 } // namespace v8 64 } // namespace v8
64 65
65 #endif // V8_REGEXP_REGEXP_UTILS_H_ 66 #endif // V8_REGEXP_REGEXP_UTILS_H_
OLDNEW
« no previous file with comments | « src/builtins/builtins-regexp.cc ('k') | src/regexp/regexp-utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698