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

Unified Diff: src/objects.h

Issue 2050343002: [regexp] Experimental support for regexp named captures (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/flag-definitions.h ('k') | src/regexp/jsregexp.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index bb00506640d83644c2b608287d3522ce641d421a..300c9f5c8dbda01cf85bf0db9cd9e74e051e0031 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -7934,7 +7934,6 @@ class JSRegExp: public JSObject {
// NOT_COMPILED: Initial value. No data has been stored in the JSRegExp yet.
// ATOM: A simple string to match against using an indexOf operation.
// IRREGEXP: Compiled with Irregexp.
- // IRREGEXP_NATIVE: Compiled to native code with Irregexp.
enum Type { NOT_COMPILED, ATOM, IRREGEXP };
enum Flag {
kNone = 0,
@@ -8027,8 +8026,11 @@ class JSRegExp: public JSObject {
static const int kIrregexpMaxRegisterCountIndex = kDataIndex + 4;
// Number of captures in the compiled regexp.
static const int kIrregexpCaptureCountIndex = kDataIndex + 5;
+ // Maps names of named capture groups (at indices 2i) to their corresponding
+ // capture group indices (at indices 2i + 1).
+ static const int kIrregexpCaptureNameMapIndex = kDataIndex + 6;
- static const int kIrregexpDataSize = kIrregexpCaptureCountIndex + 1;
+ static const int kIrregexpDataSize = kIrregexpCaptureNameMapIndex + 1;
// Offsets directly into the data fixed array.
static const int kDataTagOffset =
« no previous file with comments | « src/flag-definitions.h ('k') | src/regexp/jsregexp.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698