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

Side by Side Diff: src/allocation-site-scopes.cc

Issue 240883003: Introduce exception object and remove some uses of MaybeObject::IsFailure(). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « include/v8.h ('k') | src/elements.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 update_current_site(*scope_site); 55 update_current_site(*scope_site);
56 } 56 }
57 ASSERT(!scope_site.is_null()); 57 ASSERT(!scope_site.is_null());
58 return scope_site; 58 return scope_site;
59 } 59 }
60 60
61 61
62 void AllocationSiteCreationContext::ExitScope( 62 void AllocationSiteCreationContext::ExitScope(
63 Handle<AllocationSite> scope_site, 63 Handle<AllocationSite> scope_site,
64 Handle<JSObject> object) { 64 Handle<JSObject> object) {
65 if (!object.is_null() && !object->IsFailure()) { 65 if (!object.is_null()) {
66 bool top_level = !scope_site.is_null() && 66 bool top_level = !scope_site.is_null() &&
67 top().is_identical_to(scope_site); 67 top().is_identical_to(scope_site);
68 68
69 scope_site->set_transition_info(*object); 69 scope_site->set_transition_info(*object);
70 if (FLAG_trace_creation_allocation_sites) { 70 if (FLAG_trace_creation_allocation_sites) {
71 if (top_level) { 71 if (top_level) {
72 PrintF("*** Setting AllocationSite %p transition_info %p\n", 72 PrintF("*** Setting AllocationSite %p transition_info %p\n",
73 static_cast<void*>(*scope_site), 73 static_cast<void*>(*scope_site),
74 static_cast<void*>(*object)); 74 static_cast<void*>(*object));
75 } else { 75 } else {
(...skipping 17 matching lines...) Expand all
93 object->IsJSArray() ? "JSArray" : "JSObject", 93 object->IsJSArray() ? "JSArray" : "JSObject",
94 static_cast<void*>(*object)); 94 static_cast<void*>(*object));
95 } 95 }
96 return true; 96 return true;
97 } 97 }
98 } 98 }
99 return false; 99 return false;
100 } 100 }
101 101
102 } } // namespace v8::internal 102 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « include/v8.h ('k') | src/elements.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698