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

Issue 8728006: Implement Double.toStringAsFixed. (Closed)

Created:
9 years ago by floitsch
Modified:
9 years ago
Reviewers:
antonm, srdjan, Ivan Posva
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Implement Double.toStringAsFixed. Committed: https://code.google.com/p/dart/source/detail?r=2790

Patch Set 1 #

Patch Set 2 : Update #

Patch Set 3 : toStringAsFixed implemented. The other dtoas are prepared. #

Total comments: 2

Patch Set 4 : Add forgotten files. #

Patch Set 5 : Break 80+ line. #

Total comments: 6

Patch Set 6 : Enable more tests and small fixes. #

Total comments: 10

Patch Set 7 : Addressed comments. #

Patch Set 8 : Forgot to save a file. And disable 2 test-lines. #

Patch Set 9 : Fix syntax error. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+255 lines, -62 lines) Patch
M runtime/lib/double.cc View 1 2 3 4 5 2 chunks +28 lines, -0 lines 0 comments Download
M runtime/lib/double.dart View 1 2 3 4 5 6 2 chunks +41 lines, -50 lines 0 comments Download
M runtime/vm/bootstrap_natives.h View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
A runtime/vm/double_conversion.h View 1 2 3 1 chunk +20 lines, -0 lines 0 comments Download
A runtime/vm/double_conversion.cc View 1 2 3 4 5 6 7 8 1 chunk +150 lines, -0 lines 0 comments Download
M runtime/vm/vm_sources.gypi View 1 2 3 4 5 6 1 chunk +2 lines, -0 lines 0 comments Download
M tests/co19/co19-runtime.status View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M tests/language/src/ToStringAsFixedTest.dart View 1 2 3 4 5 6 7 4 chunks +10 lines, -12 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
floitsch
For now only toStringAsFixed is implemented. The other conversions are however prepared and would be ...
9 years ago (2011-12-02 20:20:10 UTC) #1
Ivan Posva
http://codereview.chromium.org/8728006/diff/3001/runtime/lib/double.cc File runtime/lib/double.cc (right): http://codereview.chromium.org/8728006/diff/3001/runtime/lib/double.cc#newcode10 runtime/lib/double.cc:10: #include "vm/double_conversion.h" Hard to review if the file is ...
9 years ago (2011-12-02 21:09:29 UTC) #2
floitsch
Sorry about the missing file. fyi: I get a lot of cpplint errors, so I'm ...
9 years ago (2011-12-03 13:45:58 UTC) #3
antonm
DBC http://codereview.chromium.org/8728006/diff/12001/tests/language/src/ToStringAsFixedTest.dart File tests/language/src/ToStringAsFixedTest.dart (right): http://codereview.chromium.org/8728006/diff/12001/tests/language/src/ToStringAsFixedTest.dart#newcode44 tests/language/src/ToStringAsFixedTest.dart:44: // Expect.equals("-1.1111111111111111e+21", (-1111111111111111111111.0).toStringAsFixed(8)); may you now uncomment those ...
9 years ago (2011-12-12 13:23:59 UTC) #4
floitsch
Enabled more tests. And some fixes. Note: the language/ToStringAsFixedTest now fails because 1111111111111111111111.0.toStringAsFixed(8)); redirects to ...
9 years ago (2011-12-13 16:49:02 UTC) #5
antonm
Thanks a lot, Florian. http://codereview.chromium.org/8728006/diff/12001/tests/language/src/ToStringAsFixedTest.dart File tests/language/src/ToStringAsFixedTest.dart (right): http://codereview.chromium.org/8728006/diff/12001/tests/language/src/ToStringAsFixedTest.dart#newcode65 tests/language/src/ToStringAsFixedTest.dart:65: Expect.equals("-0", (-0.0).toStringAsFixed(0)); It's up to ...
9 years ago (2011-12-14 06:44:44 UTC) #6
floitsch
http://codereview.chromium.org/8728006/diff/12001/tests/language/src/ToStringAsFixedTest.dart File tests/language/src/ToStringAsFixedTest.dart (right): http://codereview.chromium.org/8728006/diff/12001/tests/language/src/ToStringAsFixedTest.dart#newcode65 tests/language/src/ToStringAsFixedTest.dart:65: Expect.equals("-0", (-0.0).toStringAsFixed(0)); On 2011/12/14 06:44:44, antonm wrote: > It's ...
9 years ago (2011-12-14 09:23:48 UTC) #7
Ivan Posva
Only looked at the code for ToStringAsFixed in the new double_conversion.cc file: LGTM with comments. ...
9 years ago (2011-12-20 00:30:03 UTC) #8
floitsch
http://codereview.chromium.org/8728006/diff/17001/runtime/vm/double_conversion.cc File runtime/vm/double_conversion.cc (right): http://codereview.chromium.org/8728006/diff/17001/runtime/vm/double_conversion.cc#newcode65 runtime/vm/double_conversion.cc:65: if (!(isnan(d) || (kLowerBoundary < d && d < ...
9 years ago (2011-12-22 21:53:20 UTC) #9
floitsch
9 years ago (2011-12-22 22:02:03 UTC) #10
Forgot to save a file.
Also disabled to test-lines.

Powered by Google App Engine
This is Rietveld 408576698