V8 API Reference, 7.2.502.16 (for Deno 0.2.4)
js-regexp-string-iterator.h
1 // Copyright 2018 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 #ifndef V8_OBJECTS_JS_REGEXP_STRING_ITERATOR_H_
6 #define V8_OBJECTS_JS_REGEXP_STRING_ITERATOR_H_
7 
8 #include "src/objects/js-objects.h"
9 
10 // Has to be the last include (doesn't have include guards):
11 #include "src/objects/object-macros.h"
12 
13 namespace v8 {
14 namespace internal {
15 
17  public:
18  // [regexp]: the [[IteratingRegExp]] internal property.
19  DECL_ACCESSORS(iterating_regexp, Object)
20 
21  // [string]: The [[IteratedString]] internal property.
22  DECL_ACCESSORS2(iterating_string, String)
23 
24  DECL_INT_ACCESSORS(flags)
25 
26  // [boolean]: The [[Done]] internal property.
27  DECL_BOOLEAN_ACCESSORS(done)
28 
29  // [boolean]: The [[Global]] internal property.
30  DECL_BOOLEAN_ACCESSORS(global)
31 
32  // [boolean]: The [[Unicode]] internal property.
33  DECL_BOOLEAN_ACCESSORS(unicode)
34 
35  DECL_CAST(JSRegExpStringIterator)
36  DECL_PRINTER(JSRegExpStringIterator)
37  DECL_VERIFIER(JSRegExpStringIterator)
38 
39  // Layout description.
40 #define JS_REGEXP_STRING_ITERATOR_FIELDS(V) \
41  V(kIteratingRegExpOffset, kTaggedSize) \
42  V(kIteratedStringOffset, kTaggedSize) \
43  V(kFlagsOffset, kTaggedSize) \
44  /* Header size. */ \
45  V(kSize, 0)
46 
47  DEFINE_FIELD_OFFSET_CONSTANTS(JSObject::kHeaderSize,
48  JS_REGEXP_STRING_ITERATOR_FIELDS)
49 #undef JS_REGEXP_STRING_ITERATOR_FIELDS
50 
51  static const int kDoneBit = 0;
52  static const int kGlobalBit = 1;
53  static const int kUnicodeBit = 2;
54 
55  private:
56  DISALLOW_IMPLICIT_CONSTRUCTORS(JSRegExpStringIterator);
57 };
58 
59 } // namespace internal
60 } // namespace v8
61 
62 #include "src/objects/object-macros-undef.h"
63 
64 #endif // V8_OBJECTS_JS_REGEXP_STRING_ITERATOR_H_
Definition: libplatform.h:13