OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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 <stdlib.h> | 5 #include <stdlib.h> |
6 #include <sstream> | 6 #include <sstream> |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "src/api.h" | 9 #include "src/api.h" |
10 #include "src/objects.h" | 10 #include "src/objects.h" |
(...skipping 1082 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1093 } | 1093 } |
1094 | 1094 |
1095 | 1095 |
1096 TEST(SubclassPromiseBuiltin) { | 1096 TEST(SubclassPromiseBuiltin) { |
1097 // Avoid eventual completion of in-object slack tracking. | 1097 // Avoid eventual completion of in-object slack tracking. |
1098 FLAG_inline_construct = false; | 1098 FLAG_inline_construct = false; |
1099 FLAG_always_opt = false; | 1099 FLAG_always_opt = false; |
1100 CcTest::InitializeVM(); | 1100 CcTest::InitializeVM(); |
1101 v8::HandleScope scope(CcTest::isolate()); | 1101 v8::HandleScope scope(CcTest::isolate()); |
1102 | 1102 |
1103 const int first_field = 4; | 1103 const int first_field = 5; |
1104 TestSubclassBuiltin("A1", JS_PROMISE_TYPE, "Promise", | 1104 TestSubclassBuiltin("A1", JS_PROMISE_TYPE, "Promise", |
1105 "function(resolve, reject) { resolve('ok'); }", | 1105 "function(resolve, reject) { resolve('ok'); }", |
1106 first_field); | 1106 first_field); |
1107 } | 1107 } |
1108 | 1108 |
1109 | 1109 |
1110 TEST(SubclassPromiseBuiltinNoInlineNew) { | 1110 TEST(SubclassPromiseBuiltinNoInlineNew) { |
1111 FLAG_inline_new = false; | 1111 FLAG_inline_new = false; |
1112 TestSubclassPromiseBuiltin(); | 1112 TestSubclassPromiseBuiltin(); |
1113 } | 1113 } |
OLD | NEW |