OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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_STRING_BUILDER_H_ | 5 #ifndef V8_STRING_BUILDER_H_ |
6 #define V8_STRING_BUILDER_H_ | 6 #define V8_STRING_BUILDER_H_ |
7 | 7 |
8 #include "src/v8.h" | 8 #include "src/objects-inl.h" |
| 9 #include "src/utils.h" |
9 | 10 |
10 namespace v8 { | 11 namespace v8 { |
11 namespace internal { | 12 namespace internal { |
12 | 13 |
13 const int kStringBuilderConcatHelperLengthBits = 11; | 14 const int kStringBuilderConcatHelperLengthBits = 11; |
14 const int kStringBuilderConcatHelperPositionBits = 19; | 15 const int kStringBuilderConcatHelperPositionBits = 19; |
15 | 16 |
16 typedef BitField<int, 0, kStringBuilderConcatHelperLengthBits> | 17 typedef BitField<int, 0, kStringBuilderConcatHelperLengthBits> |
17 StringBuilderSubstringLength; | 18 StringBuilderSubstringLength; |
18 typedef BitField<int, kStringBuilderConcatHelperLengthBits, | 19 typedef BitField<int, kStringBuilderConcatHelperLengthBits, |
(...skipping 402 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
421 DCHECK_EQ(String::TWO_BYTE_ENCODING, encoding_); | 422 DCHECK_EQ(String::TWO_BYTE_ENCODING, encoding_); |
422 SeqTwoByteString::cast(*current_part_) | 423 SeqTwoByteString::cast(*current_part_) |
423 ->SeqTwoByteStringSet(current_index_++, c); | 424 ->SeqTwoByteStringSet(current_index_++, c); |
424 } | 425 } |
425 if (current_index_ == part_length_) Extend(); | 426 if (current_index_ == part_length_) Extend(); |
426 } | 427 } |
427 } | 428 } |
428 } // namespace v8::internal | 429 } // namespace v8::internal |
429 | 430 |
430 #endif // V8_STRING_BUILDER_H_ | 431 #endif // V8_STRING_BUILDER_H_ |
OLD | NEW |