OLD | NEW |
---|---|
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 <iomanip> | 5 #include <iomanip> |
6 #include <sstream> | 6 #include <sstream> |
7 | 7 |
8 #include "src/v8.h" | 8 #include "src/v8.h" |
9 | 9 |
10 #include "src/accessors.h" | 10 #include "src/accessors.h" |
(...skipping 10309 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
10320 return true; | 10320 return true; |
10321 } | 10321 } |
10322 if (filter[filter.length() - 1] == '*' && | 10322 if (filter[filter.length() - 1] == '*' && |
10323 name->IsUtf8EqualTo(filter.SubVector(0, filter.length() - 1), true)) { | 10323 name->IsUtf8EqualTo(filter.SubVector(0, filter.length() - 1), true)) { |
10324 return true; | 10324 return true; |
10325 } | 10325 } |
10326 return false; | 10326 return false; |
10327 } | 10327 } |
10328 | 10328 |
10329 | 10329 |
10330 Handle<String> JSFunction::GetDebugName(Handle<JSFunction> function) { | |
10331 Isolate* isolate = function->GetIsolate(); | |
10332 Handle<Object> name = | |
10333 JSObject::GetDataProperty(function, isolate->factory()->name_string()); | |
10334 String* debug_name = NULL; | |
yurys
2015/03/13 14:18:21
You should avoid raw pointers in methods that may
kozy
2015/03/13 14:54:47
Done.
| |
10335 if (name->IsString()) | |
10336 debug_name = String::cast(*name); | |
10337 else | |
10338 debug_name = function->shared()->DebugName(); | |
10339 return handle(debug_name, isolate); | |
10340 } | |
10341 | |
10342 | |
10330 void Oddball::Initialize(Isolate* isolate, | 10343 void Oddball::Initialize(Isolate* isolate, |
10331 Handle<Oddball> oddball, | 10344 Handle<Oddball> oddball, |
10332 const char* to_string, | 10345 const char* to_string, |
10333 Handle<Object> to_number, | 10346 Handle<Object> to_number, |
10334 byte kind) { | 10347 byte kind) { |
10335 Handle<String> internalized_to_string = | 10348 Handle<String> internalized_to_string = |
10336 isolate->factory()->InternalizeUtf8String(to_string); | 10349 isolate->factory()->InternalizeUtf8String(to_string); |
10337 oddball->set_to_string(*internalized_to_string); | 10350 oddball->set_to_string(*internalized_to_string); |
10338 oddball->set_to_number(*to_number); | 10351 oddball->set_to_number(*to_number); |
10339 oddball->set_kind(kind); | 10352 oddball->set_kind(kind); |
(...skipping 6789 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
17129 CompilationInfo* info) { | 17142 CompilationInfo* info) { |
17130 Handle<DependentCode> codes = DependentCode::InsertCompilationInfo( | 17143 Handle<DependentCode> codes = DependentCode::InsertCompilationInfo( |
17131 handle(cell->dependent_code(), info->isolate()), | 17144 handle(cell->dependent_code(), info->isolate()), |
17132 DependentCode::kPropertyCellChangedGroup, info->object_wrapper()); | 17145 DependentCode::kPropertyCellChangedGroup, info->object_wrapper()); |
17133 if (*codes != cell->dependent_code()) cell->set_dependent_code(*codes); | 17146 if (*codes != cell->dependent_code()) cell->set_dependent_code(*codes); |
17134 info->dependencies(DependentCode::kPropertyCellChangedGroup)->Add( | 17147 info->dependencies(DependentCode::kPropertyCellChangedGroup)->Add( |
17135 cell, info->zone()); | 17148 cell, info->zone()); |
17136 } | 17149 } |
17137 | 17150 |
17138 } } // namespace v8::internal | 17151 } } // namespace v8::internal |
OLD | NEW |