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

Issue 7291022: Make date parser handle all ES5 Date Time Strings correctly. (Closed)

Created:
9 years, 5 months ago by Lasse Reichstein
Modified:
9 years, 5 months ago
Reviewers:
Erik Corry
CC:
v8-dev
Visibility:
Public.

Description

Make date parser handle all ES5 Date Time Strings correctly. This means that ES5 Date Time Strings will default to UTC if timezone is absent. Handle as many legacy strings as possible the same way as before BUG=v8:1498 TEST=mjsunit/date Committed: http://code.google.com/p/v8/source/detail?r=8513

Patch Set 1 #

Total comments: 9

Patch Set 2 : Address review comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+589 lines, -79 lines) Patch
M src/date.js View 2 chunks +16 lines, -5 lines 0 comments Download
M src/dateparser.h View 1 6 chunks +170 lines, -28 lines 0 comments Download
M src/dateparser.cc View 5 chunks +38 lines, -4 lines 0 comments Download
M src/dateparser-inl.h View 1 3 chunks +242 lines, -39 lines 0 comments Download
M test/mjsunit/date.js View 1 1 chunk +120 lines, -0 lines 0 comments Download
M test/mjsunit/date-parse.js View 1 chunk +3 lines, -3 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
Lasse Reichstein
9 years, 5 months ago (2011-07-01 09:57:44 UTC) #1
Erik Corry
LGTM Please be sure to check performance and non-V8 test suites before committing. http://codereview.chromium.org/7291022/diff/1/src/dateparser-inl.h File ...
9 years, 5 months ago (2011-07-01 10:22:46 UTC) #2
Lasse Reichstein
9 years, 5 months ago (2011-07-01 10:49:52 UTC) #3
http://codereview.chromium.org/7291022/diff/1/src/dateparser.h
File src/dateparser.h (right):

http://codereview.chromium.org/7291022/diff/1/src/dateparser.h#newcode240
src/dateparser.h:240: kInvalidTokenTag = -5,
No. Fixed.

http://codereview.chromium.org/7291022/diff/1/src/dateparser.h#newcode370
src/dateparser.h:370: return index_ < kSize ? (comp_[index_++] = n, true) :
false;
Indeed, rewritten.

http://codereview.chromium.org/7291022/diff/1/src/dateparser.h#newcode378
src/dateparser.h:378: 
On 2011/07/01 10:22:46, Erik Corry wrote:
> Blank line above private: rather than below it.

Done.

http://codereview.chromium.org/7291022/diff/1/test/mjsunit/date.js
File test/mjsunit/date.js (right):

http://codereview.chromium.org/7291022/diff/1/test/mjsunit/date.js#newcode272
test/mjsunit/date.js:272: assertEquals(68338203500,
Date.parse("+001972-03T23:50:03.500+01:00"));
Adding more time-zone based tests.

Powered by Google App Engine
This is Rietveld 408576698