OLD | NEW |
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 #include "src/objects.h" | 5 #include "src/objects.h" |
6 | 6 |
7 #include "src/bootstrapper.h" | 7 #include "src/bootstrapper.h" |
8 #include "src/disasm.h" | 8 #include "src/disasm.h" |
9 #include "src/disassembler.h" | 9 #include "src/disassembler.h" |
10 #include "src/field-type.h" | 10 #include "src/field-type.h" |
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
159 JSWeakSet::cast(this)->JSWeakSetVerify(); | 159 JSWeakSet::cast(this)->JSWeakSetVerify(); |
160 break; | 160 break; |
161 case JS_REGEXP_TYPE: | 161 case JS_REGEXP_TYPE: |
162 JSRegExp::cast(this)->JSRegExpVerify(); | 162 JSRegExp::cast(this)->JSRegExpVerify(); |
163 break; | 163 break; |
164 case FILLER_TYPE: | 164 case FILLER_TYPE: |
165 break; | 165 break; |
166 case JS_PROXY_TYPE: | 166 case JS_PROXY_TYPE: |
167 JSProxy::cast(this)->JSProxyVerify(); | 167 JSProxy::cast(this)->JSProxyVerify(); |
168 break; | 168 break; |
169 case JS_MODULE_TYPE: | |
170 JSModule::cast(this)->JSModuleVerify(); | |
171 break; | |
172 case FOREIGN_TYPE: | 169 case FOREIGN_TYPE: |
173 Foreign::cast(this)->ForeignVerify(); | 170 Foreign::cast(this)->ForeignVerify(); |
174 break; | 171 break; |
175 case SHARED_FUNCTION_INFO_TYPE: | 172 case SHARED_FUNCTION_INFO_TYPE: |
176 SharedFunctionInfo::cast(this)->SharedFunctionInfoVerify(); | 173 SharedFunctionInfo::cast(this)->SharedFunctionInfoVerify(); |
177 break; | 174 break; |
178 case JS_MESSAGE_OBJECT_TYPE: | 175 case JS_MESSAGE_OBJECT_TYPE: |
179 JSMessageObject::cast(this)->JSMessageObjectVerify(); | 176 JSMessageObject::cast(this)->JSMessageObjectVerify(); |
180 break; | 177 break; |
181 case JS_ARRAY_BUFFER_TYPE: | 178 case JS_ARRAY_BUFFER_TYPE: |
(...skipping 645 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
827 CHECK(arr->get(JSRegExp::kIrregexpMaxRegisterCountIndex)->IsSmi()); | 824 CHECK(arr->get(JSRegExp::kIrregexpMaxRegisterCountIndex)->IsSmi()); |
828 break; | 825 break; |
829 } | 826 } |
830 default: | 827 default: |
831 CHECK_EQ(JSRegExp::NOT_COMPILED, TypeTag()); | 828 CHECK_EQ(JSRegExp::NOT_COMPILED, TypeTag()); |
832 CHECK(data()->IsUndefined(isolate)); | 829 CHECK(data()->IsUndefined(isolate)); |
833 break; | 830 break; |
834 } | 831 } |
835 } | 832 } |
836 | 833 |
837 void JSModule::JSModuleVerify() { CHECK(IsJSModule()); } | |
838 | 834 |
839 void JSProxy::JSProxyVerify() { | 835 void JSProxy::JSProxyVerify() { |
840 CHECK(IsJSProxy()); | 836 CHECK(IsJSProxy()); |
841 VerifyPointer(target()); | 837 VerifyPointer(target()); |
842 VerifyPointer(handler()); | 838 VerifyPointer(handler()); |
843 Isolate* isolate = GetIsolate(); | 839 Isolate* isolate = GetIsolate(); |
844 CHECK_EQ(target()->IsCallable(), map()->is_callable()); | 840 CHECK_EQ(target()->IsCallable(), map()->is_callable()); |
845 CHECK_EQ(target()->IsConstructor(), map()->is_constructor()); | 841 CHECK_EQ(target()->IsConstructor(), map()->is_constructor()); |
846 CHECK(hash()->IsSmi() || hash()->IsUndefined(isolate)); | 842 CHECK(hash()->IsSmi() || hash()->IsUndefined(isolate)); |
847 CHECK(map()->prototype()->IsNull(isolate)); | 843 CHECK(map()->prototype()->IsNull(isolate)); |
(...skipping 488 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1336 | 1332 |
1337 // Both are done at the same time. | 1333 // Both are done at the same time. |
1338 CHECK_EQ(new_it.done(), old_it.done()); | 1334 CHECK_EQ(new_it.done(), old_it.done()); |
1339 } | 1335 } |
1340 | 1336 |
1341 | 1337 |
1342 #endif // DEBUG | 1338 #endif // DEBUG |
1343 | 1339 |
1344 } // namespace internal | 1340 } // namespace internal |
1345 } // namespace v8 | 1341 } // namespace v8 |
OLD | NEW |