| Index: sdk/lib/core/int.dart
|
| diff --git a/sdk/lib/core/int.dart b/sdk/lib/core/int.dart
|
| index 1c17a317b39002935fe4c7d65be09445ce2309d4..c06a3ee0f8d9fb40438055905a7db2cf1fa3bada 100644
|
| --- a/sdk/lib/core/int.dart
|
| +++ b/sdk/lib/core/int.dart
|
| @@ -19,6 +19,20 @@ part of dart.core;
|
| */
|
| abstract class int extends num {
|
| /**
|
| + * Returns the integer value of the given environment declaration [name].
|
| + *
|
| + * The result is the same as would be returned by:
|
| + *
|
| + * int.parse(const String.fromEnvironment(name, defaultValue: ""),
|
| + * (_) => defaultValue)
|
| + *
|
| + * Example:
|
| + *
|
| + * const int.fromEnvironment("defaultPort", defaultValue: 80)
|
| + */
|
| + external const factory int.fromEnvironment(String name, {int defaultValue});
|
| +
|
| + /**
|
| * Bit-wise and operator.
|
| *
|
| * Treating both `this` and [other] as sufficiently large two's component
|
| @@ -252,12 +266,4 @@ abstract class int extends num {
|
| external static int parse(String source,
|
| { int radix,
|
| int onError(String source) });
|
| -
|
| - /**
|
| - * Returns the integer value for the given environment variable
|
| - * [name] or [defaultValue] if [name] is not present. If the value
|
| - * of the environment variable is not a valid integer literal a
|
| - * [FormatException] is thrown.
|
| - */
|
| - external const factory int.fromEnvironment(String name, {int defaultValue});
|
| }
|
|
|