Index: lib/json/json.dart |
diff --git a/lib/json/json.dart b/lib/json/json.dart |
index a2fc308e34ba7b53517cbe023d9543b1893646ec..5238c15b8a56ee99ef04d0ea09cf8be20c7cbb0a 100644 |
--- a/lib/json/json.dart |
+++ b/lib/json/json.dart |
@@ -1,9 +1,11 @@ |
-// Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
+// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
// for details. All rights reserved. Use of this source code is governed by a |
// BSD-style license that can be found in the LICENSE file. |
#library("dart:json"); |
+#import('dart:math'); |
+ |
// Pure Dart implementation of JSON protocol. |
/** |
@@ -289,7 +291,7 @@ class _JsonParser { |
} |
final codeString = json.substring(position + 1, position + 5); |
try { |
- c = Math.parseInt('0x${codeString}'); |
+ c = parseInt('0x${codeString}'); |
} catch (var e) { |
_error('Invalid unicode esacape sequence'); |
} |
@@ -347,9 +349,9 @@ class _JsonParser { |
String number = json.substring(startPos, position); |
if (isInt) { |
- return Math.parseInt(number); |
+ return parseInt(number); |
} else { |
- return Math.parseDouble(number); |
+ return parseDouble(number); |
} |
} |