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

Side by Side Diff: src/objects.cc

Issue 3135026: Merge flush code phase into marking phase. (Closed)
Patch Set: returned checked casts Created 10 years, 4 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
« no previous file with comments | « src/objects.h ('k') | src/objects-inl.h » ('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 2006-2009 the V8 project authors. All rights reserved. 1 // Copyright 2006-2009 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 5081 matching lines...) Expand 10 before | Expand all | Expand 10 after
5092 Object* symbol = Heap::LookupAsciiSymbol(to_string); 5092 Object* symbol = Heap::LookupAsciiSymbol(to_string);
5093 if (symbol->IsFailure()) return symbol; 5093 if (symbol->IsFailure()) return symbol;
5094 set_to_string(String::cast(symbol)); 5094 set_to_string(String::cast(symbol));
5095 set_to_number(to_number); 5095 set_to_number(to_number);
5096 return this; 5096 return this;
5097 } 5097 }
5098 5098
5099 5099
5100 bool SharedFunctionInfo::HasSourceCode() { 5100 bool SharedFunctionInfo::HasSourceCode() {
5101 return !script()->IsUndefined() && 5101 return !script()->IsUndefined() &&
5102 !Script::cast(script())->source()->IsUndefined(); 5102 !reinterpret_cast<Script*>(script())->source()->IsUndefined();
5103 } 5103 }
5104 5104
5105 5105
5106 Object* SharedFunctionInfo::GetSourceCode() { 5106 Object* SharedFunctionInfo::GetSourceCode() {
5107 HandleScope scope; 5107 HandleScope scope;
5108 if (script()->IsUndefined()) return Heap::undefined_value(); 5108 if (script()->IsUndefined()) return Heap::undefined_value();
5109 Object* source = Script::cast(script())->source(); 5109 Object* source = Script::cast(script())->source();
5110 if (source->IsUndefined()) return Heap::undefined_value(); 5110 if (source->IsUndefined()) return Heap::undefined_value();
5111 return *SubString(Handle<String>(String::cast(source)), 5111 return *SubString(Handle<String>(String::cast(source)),
5112 start_position(), end_position()); 5112 start_position(), end_position());
(...skipping 3660 matching lines...) Expand 10 before | Expand all | Expand 10 after
8773 if (break_point_objects()->IsUndefined()) return 0; 8773 if (break_point_objects()->IsUndefined()) return 0;
8774 // Single beak point. 8774 // Single beak point.
8775 if (!break_point_objects()->IsFixedArray()) return 1; 8775 if (!break_point_objects()->IsFixedArray()) return 1;
8776 // Multiple break points. 8776 // Multiple break points.
8777 return FixedArray::cast(break_point_objects())->length(); 8777 return FixedArray::cast(break_point_objects())->length();
8778 } 8778 }
8779 #endif 8779 #endif
8780 8780
8781 8781
8782 } } // namespace v8::internal 8782 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/objects.h ('k') | src/objects-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698