| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2010-2011 Google Inc. All rights reserved. | 2 * Copyright (c) 2010-2011 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 337 return false; | 337 return false; |
| 338 } | 338 } |
| 339 } | 339 } |
| 340 ASSERT(!v8result.IsEmpty()); | 340 ASSERT(!v8result.IsEmpty()); |
| 341 v8::Local<v8::Object> resultTuple = v8result->ToObject(m_isolate); | 341 v8::Local<v8::Object> resultTuple = v8result->ToObject(m_isolate); |
| 342 int code = static_cast<int>(resultTuple->Get(0)->ToInteger(m_isolate)->Value
()); | 342 int code = static_cast<int>(resultTuple->Get(0)->ToInteger(m_isolate)->Value
()); |
| 343 switch (code) { | 343 switch (code) { |
| 344 case 0: | 344 case 0: |
| 345 { | 345 { |
| 346 v8::Local<v8::Value> normalResult = resultTuple->Get(1); | 346 v8::Local<v8::Value> normalResult = resultTuple->Get(1); |
| 347 RefPtr<JSONValue> jsonResult = v8ToJSONValue(m_isolate, normalResult
, JSONValue::maxDepth); | 347 NonThrowableExceptionState exceptionState; |
| 348 RefPtr<JSONValue> jsonResult = ScriptValue::to<JSONValuePtr>(m_isola
te, normalResult, exceptionState); |
| 348 if (jsonResult) | 349 if (jsonResult) |
| 349 *result = jsonResult->asObject(); | 350 *result = jsonResult->asObject(); |
| 350 // Call stack may have changed after if the edited function was on t
he stack. | 351 // Call stack may have changed after if the edited function was on t
he stack. |
| 351 if (!preview && isPaused()) | 352 if (!preview && isPaused()) |
| 352 *newCallFrames = currentCallFrames(); | 353 *newCallFrames = currentCallFrames(); |
| 353 return true; | 354 return true; |
| 354 } | 355 } |
| 355 // Compile error. | 356 // Compile error. |
| 356 case 1: | 357 case 1: |
| 357 { | 358 { |
| (...skipping 431 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 789 *lineNumber = message->GetLineNumber(); | 790 *lineNumber = message->GetLineNumber(); |
| 790 *columnNumber = message->GetStartColumn(); | 791 *columnNumber = message->GetStartColumn(); |
| 791 v8::Handle<v8::StackTrace> messageStackTrace = message->GetStackTrac
e(); | 792 v8::Handle<v8::StackTrace> messageStackTrace = message->GetStackTrac
e(); |
| 792 if (!messageStackTrace.IsEmpty() && messageStackTrace->GetFrameCount
() > 0) | 793 if (!messageStackTrace.IsEmpty() && messageStackTrace->GetFrameCount
() > 0) |
| 793 *stackTrace = createScriptCallStack(m_isolate, messageStackTrace
, messageStackTrace->GetFrameCount()); | 794 *stackTrace = createScriptCallStack(m_isolate, messageStackTrace
, messageStackTrace->GetFrameCount()); |
| 794 } | 795 } |
| 795 } | 796 } |
| 796 } | 797 } |
| 797 | 798 |
| 798 } // namespace blink | 799 } // namespace blink |
| OLD | NEW |