Index: lib/core/int.dart |
diff --git a/lib/core/int.dart b/lib/core/int.dart |
index 404d10a4d091f81490fc811fb50656c231802dcf..0855a62b6346bc89cb0e7dedec350eb5107e8f22 100644 |
--- a/lib/core/int.dart |
+++ b/lib/core/int.dart |
@@ -24,4 +24,20 @@ abstract class int implements num { |
int floor(); |
int ceil(); |
int truncate(); |
+ /** |
+ * Returns a representation of this [int] value. |
+ * |
+ * It should always be the case that if 'i' is an [int] value, then |
+ * [:i == int.parse(i.toString())]. |
+ */ |
+ String toString(); |
+ |
+ /** |
+ * Parse [source] as an integer literal and return its value. |
+ * |
+ * Accepts "0x" prefix for hexadecimal numbers, otherwise defaults |
+ * to base-10. |
+ * Throws a [FormatException] if [source] is not a valid integer literal. |
+ */ |
+ external static int parse(String source); |
} |