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

Side by Side Diff: test/cctest/test-inobject-slack-tracking.cc

Issue 2080243003: Use instance type in Object.prototype.toString(). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Delete empty line Created 4 years, 6 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
« src/objects.cc ('K') | « src/types.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 907 matching lines...) Expand 10 before | Expand all | Expand 10 after
918 918
919 919
920 TEST(SubclassErrorBuiltin) { 920 TEST(SubclassErrorBuiltin) {
921 // Avoid eventual completion of in-object slack tracking. 921 // Avoid eventual completion of in-object slack tracking.
922 FLAG_inline_construct = false; 922 FLAG_inline_construct = false;
923 FLAG_always_opt = false; 923 FLAG_always_opt = false;
924 CcTest::InitializeVM(); 924 CcTest::InitializeVM();
925 v8::HandleScope scope(CcTest::isolate()); 925 v8::HandleScope scope(CcTest::isolate());
926 926
927 const int first_field = 2; 927 const int first_field = 2;
928 TestSubclassBuiltin("A1", JS_OBJECT_TYPE, "Error", "'err'", first_field); 928 TestSubclassBuiltin("A1", JS_ERROR_TYPE, "Error", "'err'", first_field);
929 TestSubclassBuiltin("A2", JS_OBJECT_TYPE, "EvalError", "'err'", first_field); 929 TestSubclassBuiltin("A2", JS_ERROR_TYPE, "EvalError", "'err'", first_field);
930 TestSubclassBuiltin("A3", JS_OBJECT_TYPE, "RangeError", "'err'", first_field); 930 TestSubclassBuiltin("A3", JS_ERROR_TYPE, "RangeError", "'err'", first_field);
931 TestSubclassBuiltin("A4", JS_OBJECT_TYPE, "ReferenceError", "'err'", 931 TestSubclassBuiltin("A4", JS_ERROR_TYPE, "ReferenceError", "'err'",
932 first_field); 932 first_field);
933 TestSubclassBuiltin("A5", JS_OBJECT_TYPE, "SyntaxError", "'err'", 933 TestSubclassBuiltin("A5", JS_ERROR_TYPE, "SyntaxError", "'err'", first_field);
934 first_field); 934 TestSubclassBuiltin("A6", JS_ERROR_TYPE, "TypeError", "'err'", first_field);
935 TestSubclassBuiltin("A6", JS_OBJECT_TYPE, "TypeError", "'err'", first_field); 935 TestSubclassBuiltin("A7", JS_ERROR_TYPE, "URIError", "'err'", first_field);
936 TestSubclassBuiltin("A7", JS_OBJECT_TYPE, "URIError", "'err'", first_field);
937 } 936 }
938 937
939 938
940 TEST(SubclassErrorBuiltinNoInlineNew) { 939 TEST(SubclassErrorBuiltinNoInlineNew) {
941 FLAG_inline_new = false; 940 FLAG_inline_new = false;
942 TestSubclassErrorBuiltin(); 941 TestSubclassErrorBuiltin();
943 } 942 }
944 943
945 944
946 TEST(SubclassNumberBuiltin) { 945 TEST(SubclassNumberBuiltin) {
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
1104 TestSubclassBuiltin("A1", JS_PROMISE_TYPE, "Promise", 1103 TestSubclassBuiltin("A1", JS_PROMISE_TYPE, "Promise",
1105 "function(resolve, reject) { resolve('ok'); }", 1104 "function(resolve, reject) { resolve('ok'); }",
1106 first_field); 1105 first_field);
1107 } 1106 }
1108 1107
1109 1108
1110 TEST(SubclassPromiseBuiltinNoInlineNew) { 1109 TEST(SubclassPromiseBuiltinNoInlineNew) {
1111 FLAG_inline_new = false; 1110 FLAG_inline_new = false;
1112 TestSubclassPromiseBuiltin(); 1111 TestSubclassPromiseBuiltin();
1113 } 1112 }
OLDNEW
« src/objects.cc ('K') | « src/types.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698