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

Side by Side Diff: src/bootstrapper.cc

Issue 155135: Change a few sites where the Handle<T>(NULL) constructor is used so... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 5 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 | « no previous file | src/handles.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-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 1538 matching lines...) Expand 10 before | Expand all | Expand 10 after
1549 1549
1550 1550
1551 Genesis::Genesis(Handle<Object> global_object, 1551 Genesis::Genesis(Handle<Object> global_object,
1552 v8::Handle<v8::ObjectTemplate> global_template, 1552 v8::Handle<v8::ObjectTemplate> global_template,
1553 v8::ExtensionConfiguration* extensions) { 1553 v8::ExtensionConfiguration* extensions) {
1554 // Link this genesis object into the stacked genesis chain. This 1554 // Link this genesis object into the stacked genesis chain. This
1555 // must be done before any early exits because the destructor 1555 // must be done before any early exits because the destructor
1556 // will always do unlinking. 1556 // will always do unlinking.
1557 previous_ = current_; 1557 previous_ = current_;
1558 current_ = this; 1558 current_ = this;
1559 result_ = NULL; 1559 result_ = Handle<Context>::null();
1560 1560
1561 // If V8 isn't running and cannot be initialized, just return. 1561 // If V8 isn't running and cannot be initialized, just return.
1562 if (!V8::IsRunning() && !V8::Initialize(NULL)) return; 1562 if (!V8::IsRunning() && !V8::Initialize(NULL)) return;
1563 1563
1564 // Before creating the roots we must save the context and restore it 1564 // Before creating the roots we must save the context and restore it
1565 // on all function exits. 1565 // on all function exits.
1566 HandleScope scope; 1566 HandleScope scope;
1567 SaveContext context; 1567 SaveContext context;
1568 1568
1569 CreateRoots(global_template, global_object); 1569 CreateRoots(global_template, global_object);
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
1617 } 1617 }
1618 1618
1619 1619
1620 // Restore statics that are thread local. 1620 // Restore statics that are thread local.
1621 char* Genesis::RestoreState(char* from) { 1621 char* Genesis::RestoreState(char* from) {
1622 current_ = *reinterpret_cast<Genesis**>(from); 1622 current_ = *reinterpret_cast<Genesis**>(from);
1623 return from + sizeof(current_); 1623 return from + sizeof(current_);
1624 } 1624 }
1625 1625
1626 } } // namespace v8::internal 1626 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/handles.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698