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

Side by Side Diff: src/objects.h

Issue 1070093002: Eagerly escape RegExp.source. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 8 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/bootstrapper.cc ('k') | src/runtime/runtime-regexp.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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_OBJECTS_H_ 5 #ifndef V8_OBJECTS_H_
6 #define V8_OBJECTS_H_ 6 #define V8_OBJECTS_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 9
10 #include "src/allocation.h" 10 #include "src/allocation.h"
(...skipping 8102 matching lines...) Expand 10 before | Expand all | Expand 10 after
8113 static const int kDataTagOffset = 8113 static const int kDataTagOffset =
8114 FixedArray::kHeaderSize + kTagIndex * kPointerSize; 8114 FixedArray::kHeaderSize + kTagIndex * kPointerSize;
8115 static const int kDataOneByteCodeOffset = 8115 static const int kDataOneByteCodeOffset =
8116 FixedArray::kHeaderSize + kIrregexpLatin1CodeIndex * kPointerSize; 8116 FixedArray::kHeaderSize + kIrregexpLatin1CodeIndex * kPointerSize;
8117 static const int kDataUC16CodeOffset = 8117 static const int kDataUC16CodeOffset =
8118 FixedArray::kHeaderSize + kIrregexpUC16CodeIndex * kPointerSize; 8118 FixedArray::kHeaderSize + kIrregexpUC16CodeIndex * kPointerSize;
8119 static const int kIrregexpCaptureCountOffset = 8119 static const int kIrregexpCaptureCountOffset =
8120 FixedArray::kHeaderSize + kIrregexpCaptureCountIndex * kPointerSize; 8120 FixedArray::kHeaderSize + kIrregexpCaptureCountIndex * kPointerSize;
8121 8121
8122 // In-object fields. 8122 // In-object fields.
8123 static const int kGlobalFieldIndex = 0; 8123 static const int kSourceFieldIndex = 0;
8124 static const int kIgnoreCaseFieldIndex = 1; 8124 static const int kGlobalFieldIndex = 1;
8125 static const int kMultilineFieldIndex = 2; 8125 static const int kIgnoreCaseFieldIndex = 2;
8126 static const int kLastIndexFieldIndex = 3; 8126 static const int kMultilineFieldIndex = 3;
8127 static const int kInObjectFieldCount = 4; 8127 static const int kLastIndexFieldIndex = 4;
8128 static const int kInObjectFieldCount = 5;
8128 8129
8129 // The uninitialized value for a regexp code object. 8130 // The uninitialized value for a regexp code object.
8130 static const int kUninitializedValue = -1; 8131 static const int kUninitializedValue = -1;
8131 8132
8132 // The compilation error value for the regexp code object. The real error 8133 // The compilation error value for the regexp code object. The real error
8133 // object is in the saved code field. 8134 // object is in the saved code field.
8134 static const int kCompilationErrorValue = -2; 8135 static const int kCompilationErrorValue = -2;
8135 8136
8136 // When we store the sweep generation at which we moved the code from the 8137 // When we store the sweep generation at which we moved the code from the
8137 // code index to the saved code index we mask it of to be in the [0:255] 8138 // code index to the saved code index we mask it of to be in the [0:255]
(...skipping 2935 matching lines...) Expand 10 before | Expand all | Expand 10 after
11073 } else { 11074 } else {
11074 value &= ~(1 << bit_position); 11075 value &= ~(1 << bit_position);
11075 } 11076 }
11076 return value; 11077 return value;
11077 } 11078 }
11078 }; 11079 };
11079 11080
11080 } } // namespace v8::internal 11081 } } // namespace v8::internal
11081 11082
11082 #endif // V8_OBJECTS_H_ 11083 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/bootstrapper.cc ('k') | src/runtime/runtime-regexp.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698