OLD | NEW |
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 3604 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3615 func->shared()->set_name(*Utils::OpenHandle(*name)); | 3615 func->shared()->set_name(*Utils::OpenHandle(*name)); |
3616 } | 3616 } |
3617 | 3617 |
3618 | 3618 |
3619 Handle<Value> Function::GetName() const { | 3619 Handle<Value> Function::GetName() const { |
3620 i::Handle<i::JSFunction> func = Utils::OpenHandle(this); | 3620 i::Handle<i::JSFunction> func = Utils::OpenHandle(this); |
3621 return Utils::ToLocal(i::Handle<i::Object>(func->shared()->name())); | 3621 return Utils::ToLocal(i::Handle<i::Object>(func->shared()->name())); |
3622 } | 3622 } |
3623 | 3623 |
3624 | 3624 |
| 3625 Handle<Value> Function::GetInferredName() const { |
| 3626 i::Handle<i::JSFunction> func = Utils::OpenHandle(this); |
| 3627 return Utils::ToLocal(i::Handle<i::Object>(func->shared()->inferred_name())); |
| 3628 } |
| 3629 |
| 3630 |
3625 ScriptOrigin Function::GetScriptOrigin() const { | 3631 ScriptOrigin Function::GetScriptOrigin() const { |
3626 i::Handle<i::JSFunction> func = Utils::OpenHandle(this); | 3632 i::Handle<i::JSFunction> func = Utils::OpenHandle(this); |
3627 if (func->shared()->script()->IsScript()) { | 3633 if (func->shared()->script()->IsScript()) { |
3628 i::Handle<i::Script> script(i::Script::cast(func->shared()->script())); | 3634 i::Handle<i::Script> script(i::Script::cast(func->shared()->script())); |
3629 v8::ScriptOrigin origin( | 3635 v8::ScriptOrigin origin( |
3630 Utils::ToLocal(i::Handle<i::Object>(script->name())), | 3636 Utils::ToLocal(i::Handle<i::Object>(script->name())), |
3631 v8::Integer::New(script->line_offset()->value()), | 3637 v8::Integer::New(script->line_offset()->value()), |
3632 v8::Integer::New(script->column_offset()->value())); | 3638 v8::Integer::New(script->column_offset()->value())); |
3633 return origin; | 3639 return origin; |
3634 } | 3640 } |
(...skipping 2531 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6166 | 6172 |
6167 | 6173 |
6168 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { | 6174 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { |
6169 HandleScopeImplementer* scope_implementer = | 6175 HandleScopeImplementer* scope_implementer = |
6170 reinterpret_cast<HandleScopeImplementer*>(storage); | 6176 reinterpret_cast<HandleScopeImplementer*>(storage); |
6171 scope_implementer->IterateThis(v); | 6177 scope_implementer->IterateThis(v); |
6172 return storage + ArchiveSpacePerThread(); | 6178 return storage + ArchiveSpacePerThread(); |
6173 } | 6179 } |
6174 | 6180 |
6175 } } // namespace v8::internal | 6181 } } // namespace v8::internal |
OLD | NEW |