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

Side by Side Diff: src/liveedit.cc

Issue 18404009: Refactor JavaScriptFrame::function() to return a JSFunction* and remove associated casts. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Remove implicit ASSERT. Created 7 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 | « src/isolate.cc ('k') | src/runtime.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 1603 matching lines...) Expand 10 before | Expand all | Expand 10 after
1614 1614
1615 1615
1616 // Check an activation against list of functions. If there is a function 1616 // Check an activation against list of functions. If there is a function
1617 // that matches, its status in result array is changed to status argument value. 1617 // that matches, its status in result array is changed to status argument value.
1618 static bool CheckActivation(Handle<JSArray> shared_info_array, 1618 static bool CheckActivation(Handle<JSArray> shared_info_array,
1619 Handle<JSArray> result, 1619 Handle<JSArray> result,
1620 StackFrame* frame, 1620 StackFrame* frame,
1621 LiveEdit::FunctionPatchabilityStatus status) { 1621 LiveEdit::FunctionPatchabilityStatus status) {
1622 if (!frame->is_java_script()) return false; 1622 if (!frame->is_java_script()) return false;
1623 1623
1624 Handle<JSFunction> function( 1624 Handle<JSFunction> function(JavaScriptFrame::cast(frame)->function());
1625 JSFunction::cast(JavaScriptFrame::cast(frame)->function()));
1626 1625
1627 Isolate* isolate = shared_info_array->GetIsolate(); 1626 Isolate* isolate = shared_info_array->GetIsolate();
1628 int len = GetArrayLength(shared_info_array); 1627 int len = GetArrayLength(shared_info_array);
1629 for (int i = 0; i < len; i++) { 1628 for (int i = 0; i < len; i++) {
1630 Object* element = shared_info_array->GetElementNoExceptionThrown(i); 1629 Object* element = shared_info_array->GetElementNoExceptionThrown(i);
1631 CHECK(element->IsJSValue()); 1630 CHECK(element->IsJSValue());
1632 Handle<JSValue> jsvalue(JSValue::cast(element)); 1631 Handle<JSValue> jsvalue(JSValue::cast(element));
1633 Handle<SharedFunctionInfo> shared = 1632 Handle<SharedFunctionInfo> shared =
1634 UnwrapSharedFunctionInfoFromJSValue(jsvalue); 1633 UnwrapSharedFunctionInfoFromJSValue(jsvalue);
1635 1634
(...skipping 489 matching lines...) Expand 10 before | Expand all | Expand 10 after
2125 2124
2126 bool LiveEditFunctionTracker::IsActive(Isolate* isolate) { 2125 bool LiveEditFunctionTracker::IsActive(Isolate* isolate) {
2127 return false; 2126 return false;
2128 } 2127 }
2129 2128
2130 #endif // ENABLE_DEBUGGER_SUPPORT 2129 #endif // ENABLE_DEBUGGER_SUPPORT
2131 2130
2132 2131
2133 2132
2134 } } // namespace v8::internal 2133 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/isolate.cc ('k') | src/runtime.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698