Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(833)

Unified Diff: sdk/lib/core/date_time.dart

Issue 324213003: Change DateTime.parse FormatException messages; update tests (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Adding better tests as per lrn@ Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/corelib/date_time_test.dart » ('j') | tests/corelib/date_time_test.dart » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/core/date_time.dart
diff --git a/sdk/lib/core/date_time.dart b/sdk/lib/core/date_time.dart
index 5cc9707a88eda48bf771d376c22cfa6b458325cc..c1ce73145df1bc1c2d320669a8b0f3b6f1cff251 100644
--- a/sdk/lib/core/date_time.dart
+++ b/sdk/lib/core/date_time.dart
@@ -239,7 +239,7 @@ class DateTime implements Comparable {
* timezonemins_opt ::= <empty> | colon_opt digit{2}
*/
final RegExp re = new RegExp(
- r'^([+-]?\d{4,5})-?(\d\d)-?(\d\d)' // The day part.
+ r'^([+-]?\d{4,6})-?(\d\d)-?(\d\d)' // The day part.
r'(?:[ T](\d\d)(?::?(\d\d)(?::?(\d\d)(.\d{1,6})?)?)?' // The time part
r'( ?[zZ]| ?([-+])(\d\d)(?::?(\d\d))?)?)?$'); // The timezone part
« no previous file with comments | « no previous file | tests/corelib/date_time_test.dart » ('j') | tests/corelib/date_time_test.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698