| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium 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 "platform/JSONParser.h" | 5 #include "platform/json/JSONParser.h" |
| 6 | 6 |
| 7 #include "platform/Decimal.h" | 7 #include "platform/Decimal.h" |
| 8 #include "platform/JSONValues.h" | 8 #include "platform/json/JSONValues.h" |
| 9 #include "wtf/text/StringBuilder.h" | 9 #include "wtf/text/StringBuilder.h" |
| 10 #include "wtf/text/StringToNumber.h" | 10 #include "wtf/text/StringToNumber.h" |
| 11 | 11 |
| 12 namespace blink { | 12 namespace blink { |
| 13 | 13 |
| 14 namespace { | 14 namespace { |
| 15 | 15 |
| 16 const int stackLimit = 1000; | 16 const int stackLimit = 1000; |
| 17 | 17 |
| 18 enum Token { | 18 enum Token { |
| (...skipping 491 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 510 std::unique_ptr<JSONValue> parseJSON(const String& json) | 510 std::unique_ptr<JSONValue> parseJSON(const String& json) |
| 511 { | 511 { |
| 512 if (json.isEmpty()) | 512 if (json.isEmpty()) |
| 513 return nullptr; | 513 return nullptr; |
| 514 if (json.is8Bit()) | 514 if (json.is8Bit()) |
| 515 return parseJSONInternal(json.characters8(), json.length()); | 515 return parseJSONInternal(json.characters8(), json.length()); |
| 516 return parseJSONInternal(json.characters16(), json.length()); | 516 return parseJSONInternal(json.characters16(), json.length()); |
| 517 } | 517 } |
| 518 | 518 |
| 519 } // namespace blink | 519 } // namespace blink |
| OLD | NEW |