| OLD | NEW | 
|---|
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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 "src/debug/debug-scopes.h" | 5 #include "src/debug/debug-scopes.h" | 
| 6 | 6 | 
| 7 #include "src/ast/scopes.h" | 7 #include "src/ast/scopes.h" | 
| 8 #include "src/debug/debug.h" | 8 #include "src/debug/debug.h" | 
| 9 #include "src/frames-inl.h" | 9 #include "src/frames-inl.h" | 
| 10 #include "src/globals.h" | 10 #include "src/globals.h" | 
| (...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 330       os << "Global:\n"; | 330       os << "Global:\n"; | 
| 331       CurrentContext()->Print(os); | 331       CurrentContext()->Print(os); | 
| 332       break; | 332       break; | 
| 333 | 333 | 
| 334     case ScopeIterator::ScopeTypeLocal: { | 334     case ScopeIterator::ScopeTypeLocal: { | 
| 335       os << "Local:\n"; | 335       os << "Local:\n"; | 
| 336       GetFunction()->shared()->scope_info()->Print(); | 336       GetFunction()->shared()->scope_info()->Print(); | 
| 337       if (!CurrentContext().is_null()) { | 337       if (!CurrentContext().is_null()) { | 
| 338         CurrentContext()->Print(os); | 338         CurrentContext()->Print(os); | 
| 339         if (CurrentContext()->has_extension()) { | 339         if (CurrentContext()->has_extension()) { | 
| 340           Handle<Object> extension(CurrentContext()->extension(), isolate_); | 340           Handle<HeapObject> extension(CurrentContext()->extension(), isolate_); | 
| 341           if (extension->IsJSContextExtensionObject()) { | 341           if (extension->IsJSContextExtensionObject()) { | 
| 342             extension->Print(os); | 342             extension->Print(os); | 
| 343           } | 343           } | 
| 344         } | 344         } | 
| 345       } | 345       } | 
| 346       break; | 346       break; | 
| 347     } | 347     } | 
| 348 | 348 | 
| 349     case ScopeIterator::ScopeTypeWith: | 349     case ScopeIterator::ScopeTypeWith: | 
| 350       os << "With:\n"; | 350       os << "With:\n"; | 
| 351       CurrentContext()->extension()->Print(os); | 351       CurrentContext()->extension()->Print(os); | 
| 352       break; | 352       break; | 
| 353 | 353 | 
| 354     case ScopeIterator::ScopeTypeCatch: | 354     case ScopeIterator::ScopeTypeCatch: | 
| 355       os << "Catch:\n"; | 355       os << "Catch:\n"; | 
| 356       CurrentContext()->extension()->Print(os); | 356       CurrentContext()->extension()->Print(os); | 
| 357       CurrentContext()->get(Context::THROWN_OBJECT_INDEX)->Print(os); | 357       CurrentContext()->get(Context::THROWN_OBJECT_INDEX)->Print(os); | 
| 358       break; | 358       break; | 
| 359 | 359 | 
| 360     case ScopeIterator::ScopeTypeClosure: | 360     case ScopeIterator::ScopeTypeClosure: | 
| 361       os << "Closure:\n"; | 361       os << "Closure:\n"; | 
| 362       CurrentContext()->Print(os); | 362       CurrentContext()->Print(os); | 
| 363       if (CurrentContext()->has_extension()) { | 363       if (CurrentContext()->has_extension()) { | 
| 364         Handle<Object> extension(CurrentContext()->extension(), isolate_); | 364         Handle<HeapObject> extension(CurrentContext()->extension(), isolate_); | 
| 365         if (extension->IsJSContextExtensionObject()) { | 365         if (extension->IsJSContextExtensionObject()) { | 
| 366           extension->Print(os); | 366           extension->Print(os); | 
| 367         } | 367         } | 
| 368       } | 368       } | 
| 369       break; | 369       break; | 
| 370 | 370 | 
| 371     case ScopeIterator::ScopeTypeScript: | 371     case ScopeIterator::ScopeTypeScript: | 
| 372       os << "Script:\n"; | 372       os << "Script:\n"; | 
| 373       CurrentContext() | 373       CurrentContext() | 
| 374           ->global_object() | 374           ->global_object() | 
| (...skipping 407 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 782         isolate_, value, Object::GetPropertyOrElement(extension, key), false); | 782         isolate_, value, Object::GetPropertyOrElement(extension, key), false); | 
| 783     RETURN_ON_EXCEPTION_VALUE( | 783     RETURN_ON_EXCEPTION_VALUE( | 
| 784         isolate_, JSObject::SetOwnPropertyIgnoreAttributes( | 784         isolate_, JSObject::SetOwnPropertyIgnoreAttributes( | 
| 785             scope_object, key, value, NONE), false); | 785             scope_object, key, value, NONE), false); | 
| 786   } | 786   } | 
| 787   return true; | 787   return true; | 
| 788 } | 788 } | 
| 789 | 789 | 
| 790 }  // namespace internal | 790 }  // namespace internal | 
| 791 }  // namespace v8 | 791 }  // namespace v8 | 
| OLD | NEW | 
|---|