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

Issue 10829459: Deprecate Math object in corelib in favor of dart:math library. (Closed)

Created:
8 years, 4 months ago by Mads Ager (google)
Modified:
8 years, 4 months ago
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Deprecate Math object in corelib in favor of dart:math library. Committed: https://code.google.com/p/dart/source/detail?r=11155

Patch Set 1 #

Total comments: 6

Patch Set 2 : Address review comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1000 lines, -1764 lines) Patch
M compiler/javatests/com/google/dart/compiler/type/TypeAnalyzerCompilerTest.java View 1 4 chunks +2 lines, -8 lines 0 comments Download
M corelib/src/bool.dart View 1 chunk +1 line, -1 line 0 comments Download
M corelib/src/corelib_sources.gypi View 1 chunk +0 lines, -1 line 0 comments Download
M corelib/src/expect.dart View 3 chunks +3 lines, -3 lines 0 comments Download
M corelib/src/implementation/date.dart View 1 chunk +5 lines, -5 lines 0 comments Download
D corelib/src/math.dart View 1 chunk +0 lines, -162 lines 0 comments Download
M editor/util/debuggertest/pets.dart View 2 chunks +4 lines, -1 line 0 comments Download
M lib/compiler/implementation/lib/core.dart View 2 chunks +2 lines, -1 line 0 comments Download
M lib/compiler/implementation/lib/coreimpl.dart View 1 chunk +1 line, -0 lines 0 comments Download
M lib/compiler/implementation/lib/io.dart View 1 1 chunk +1 line, -0 lines 0 comments Download
M lib/compiler/implementation/source_file.dart View 1 2 chunks +3 lines, -1 line 0 comments Download
M lib/compiler/implementation/tree/nodes.dart View 1 2 chunks +2 lines, -2 lines 0 comments Download
M lib/compiler/implementation/tree/tree.dart View 1 chunk +3 lines, -1 line 0 comments Download
M lib/compiler/implementation/util/uri_extras.dart View 2 chunks +2 lines, -1 line 0 comments Download
M lib/crypto/crypto.dart View 1 chunk +2 lines, -0 lines 0 comments Download
M lib/crypto/crypto_vm.dart View 1 chunk +2 lines, -0 lines 0 comments Download
M lib/crypto/hash_utils.dart View 1 chunk +1 line, -1 line 0 comments Download
M lib/json/json.dart View 3 chunks +6 lines, -4 lines 0 comments Download
M lib/uri/encode_decode.dart View 1 chunk +2 lines, -2 lines 0 comments Download
M lib/uri/uri.dart View 1 2 chunks +2 lines, -1 line 0 comments Download
M pkg/args/args.dart View 2 chunks +5 lines, -3 lines 0 comments Download
M pkg/dartdoc/dartdoc.dart View 1 chunk +1 line, -0 lines 0 comments Download
M pkg/dartdoc/utils.dart View 1 chunk +1 line, -1 line 0 comments Download
M pkg/fixnum/fixnum.dart View 1 chunk +1 line, -0 lines 0 comments Download
M pkg/fixnum/test/int_64_vm_test.dart View 1 chunk +1 line, -0 lines 0 comments Download
M pkg/intl/date_format.dart View 1 2 chunks +3 lines, -1 line 0 comments Download
M pkg/intl/lib/date_format_helpers.dart View 1 2 chunks +3 lines, -3 lines 0 comments Download
M pkg/intl/number_format.dart View 1 3 chunks +6 lines, -4 lines 0 comments Download
M pkg/unittest/interactive_html_config.dart View 4 chunks +4 lines, -3 lines 0 comments Download
M runtime/bin/file_impl.dart View 1 chunk +1 line, -1 line 0 comments Download
M runtime/bin/http_impl.dart View 3 chunks +3 lines, -3 lines 0 comments Download
M runtime/bin/http_parser.dart View 2 chunks +2 lines, -2 lines 0 comments Download
M runtime/bin/http_utils.dart View 1 chunk +1 line, -1 line 0 comments Download
M runtime/bin/io.dart View 1 chunk +1 line, -0 lines 0 comments Download
M runtime/bin/stream_util.dart View 1 chunk +1 line, -1 line 0 comments Download
M runtime/bin/websocket_impl.dart View 1 2 chunks +3 lines, -2 lines 0 comments Download
M runtime/lib/math_patch.dart View 2 chunks +2 lines, -7 lines 0 comments Download
M runtime/lib/string.dart View 2 chunks +2 lines, -2 lines 0 comments Download
M runtime/vm/object.cc View 1 2 chunks +4 lines, -1 line 0 comments Download
M samples/calculator/calculator.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/chat/chat_server_lib.dart View 2 chunks +3 lines, -1 line 0 comments Download
M samples/clock/balls.dart View 1 chunk +1 line, -1 line 0 comments Download
M samples/clock/clock.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/dartcombat/dartcombatlib.dart View 2 chunks +2 lines, -1 line 0 comments Download
M samples/isolate_html/isolate_sample.dart View 2 chunks +2 lines, -1 line 0 comments Download
M samples/logo/logo.dart View 1 chunk +2 lines, -1 line 0 comments Download
M samples/matrix/matrix_client.dart View 2 chunks +2 lines, -1 line 0 comments Download
M samples/matrix/matrix_server.dart View 2 chunks +2 lines, -1 line 0 comments Download
M samples/solar/solar.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/spirodraw/Spirodraw.dart View 2 chunks +6 lines, -4 lines 0 comments Download
M samples/sunflower/sunflower.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/swarm/swarmlib.dart View 2 chunks +2 lines, -1 line 0 comments Download
M samples/swipe/swipe.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/Dromaeo.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/common/common.dart View 1 chunk +2 lines, -1 line 0 comments Download
M samples/third_party/dromaeo/tests/dom-attr-dom.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-attr-html.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-attr-htmlidiomatic.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-modify-dom.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-modify-html.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-modify-htmlidiomatic.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-query-dom.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-query-html.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-query-htmlidiomatic.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-traverse-dom.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-traverse-html.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/third_party/dromaeo/tests/dom-traverse-htmlidiomatic.dart View 1 chunk +1 line, -0 lines 0 comments Download
M samples/ui_lib/layout/layout.dart View 1 chunk +3 lines, -1 line 0 comments Download
M samples/ui_lib/touch/touch.dart View 1 chunk +4 lines, -2 lines 0 comments Download
M samples/ui_lib/util/utilslib.dart View 1 chunk +2 lines, -0 lines 0 comments Download
M samples/ui_lib/view/view.dart View 1 chunk +2 lines, -0 lines 0 comments Download
M tests/benchmark_smoke/benchmark_lib.dart View 2 chunks +2 lines, -1 line 0 comments Download
M tests/co19/co19-dart2js.status View 1 chunk +87 lines, -0 lines 0 comments Download
M tests/co19/co19-runtime.status View 1 chunk +89 lines, -0 lines 0 comments Download
M tests/corelib/collection_to_string_test.dart View 4 chunks +10 lines, -4 lines 0 comments Download
M tests/corelib/math_parse_double_test.dart View 1 1 chunk +0 lines, -129 lines 0 comments Download
M tests/corelib/math_test.dart View 1 1 chunk +0 lines, -514 lines 0 comments Download
M tests/corelib/min_max_test.dart View 1 1 chunk +0 lines, -521 lines 0 comments Download
M tests/corelib/stopwatch_test.dart View 6 chunks +11 lines, -8 lines 0 comments Download
M tests/isolate/mandel_isolate_test.dart View 2 chunks +2 lines, -1 line 0 comments Download
M tests/language/arithmetic_test.dart View 6 chunks +44 lines, -38 lines 0 comments Download
M tests/language/closure_type_test.dart View 2 chunks +8 lines, -1 line 0 comments Download
M tests/language/intrinsified_methods_test.dart View 2 chunks +6 lines, -4 lines 0 comments Download
M tests/language/math_vm_test.dart View 3 chunks +4 lines, -2 lines 0 comments Download
A + tests/lib/math/math2_test.dart View 1 3 chunks +1 line, -252 lines 0 comments Download
A + tests/lib/math/math_parse_double_test.dart View 1 2 chunks +3 lines, -10 lines 0 comments Download
A tests/lib/math/min_max_test.dart View 1 1 chunk +524 lines, -0 lines 0 comments Download
M tests/standalone/io/http_date_test.dart View 1 chunk +2 lines, -0 lines 0 comments Download
M tests/standalone/io/http_headers_test.dart View 1 chunk +2 lines, -0 lines 0 comments Download
M tests/standalone/io/http_parser_test.dart View 5 chunks +6 lines, -4 lines 0 comments Download
M tests/standalone/io/http_server_socket_test.dart View 3 chunks +3 lines, -2 lines 0 comments Download
M tests/standalone/io/mime_multipart_parser_test.dart View 2 chunks +3 lines, -1 line 0 comments Download
M tests/standalone/io/options_test.dart View 2 chunks +8 lines, -6 lines 0 comments Download
M tests/standalone/io/process_check_arguments_script.dart View 1 chunk +3 lines, -2 lines 0 comments Download
M tests/standalone/io/process_stderr_test.dart View 2 chunks +5 lines, -3 lines 0 comments Download
M tests/standalone/io/process_stdout_test.dart View 2 chunks +3 lines, -1 line 0 comments Download
M tests/standalone/io/web_socket_protocol_processor_test.dart View 2 chunks +3 lines, -1 line 0 comments Download
M tools/create_sdk.py View 1 2 chunks +2 lines, -0 lines 0 comments Download
M tools/ddbg.dart View 1 chunk +1 line, -0 lines 0 comments Download
M tools/testing/dart/test_options.dart View 2 chunks +2 lines, -1 line 0 comments Download
M utils/css/css.dart View 1 chunk +2 lines, -1 line 0 comments Download
M utils/pub/pub.dart View 2 chunks +2 lines, -1 line 0 comments Download
M utils/pub/version.dart View 4 chunks +7 lines, -5 lines 0 comments Download
M utils/pub/version_solver.dart View 1 2 chunks +2 lines, -1 line 0 comments Download
M utils/pub/yaml/yaml.dart View 1 chunk +2 lines, -0 lines 0 comments Download
M utils/template/template.dart View 1 chunk +2 lines, -1 line 0 comments Download
M utils/tests/pub/test_pub.dart View 2 chunks +2 lines, -1 line 0 comments Download
M utils/tests/pub/yaml_test.dart View 2 chunks +4 lines, -2 lines 0 comments Download
M utils/tests/string_encoding/utf8_benchmarks.dart View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
Mads Ager (google)
Auch, this is passing tests locally, but I'm sure I have missed something somewhere. Time ...
8 years, 4 months ago (2012-08-21 17:19:49 UTC) #1
Mads Ager (google)
Ivan, could you have a look at runtime/vm/object.cc changes to import dart:math in core and ...
8 years, 4 months ago (2012-08-21 17:26:02 UTC) #2
scheglov
> Konstantin, could you have a look at the java tests I have changed. It ...
8 years, 4 months ago (2012-08-21 18:26:42 UTC) #3
ahe
lib/compiler LGTM. Nice work!
8 years, 4 months ago (2012-08-21 19:50:52 UTC) #4
Anders Johnsen
LGTM! https://chromiumcodereview.appspot.com/10829459/diff/1/runtime/bin/websocket_impl.dart File runtime/bin/websocket_impl.dart (right): https://chromiumcodereview.appspot.com/10829459/diff/1/runtime/bin/websocket_impl.dart#newcode742 runtime/bin/websocket_impl.dart:742: int r = (random.nextDouble() * 0x100000000).toInt(); Use nextInt(0x100000000)? ...
8 years, 4 months ago (2012-08-22 07:37:53 UTC) #5
Mads Ager (google)
8 years, 4 months ago (2012-08-22 13:42:41 UTC) #6
https://chromiumcodereview.appspot.com/10829459/diff/1/runtime/bin/websocket_...
File runtime/bin/websocket_impl.dart (right):

https://chromiumcodereview.appspot.com/10829459/diff/1/runtime/bin/websocket_...
runtime/bin/websocket_impl.dart:742: int r = (random.nextDouble() *
0x100000000).toInt();
On 2012/08/22 07:37:53, ajohnsen wrote:
> Use nextInt(0x100000000)?

Done.

https://chromiumcodereview.appspot.com/10829459/diff/1/runtime/bin/websocket_...
runtime/bin/websocket_impl.dart:746: _hash = (random.nextDouble() *
0x100000000).toInt();
On 2012/08/22 07:37:53, ajohnsen wrote:
> Ditto.

Done.

https://chromiumcodereview.appspot.com/10829459/diff/1/tests/corelib/math_tes...
File tests/corelib/math_test.dart (right):

https://chromiumcodereview.appspot.com/10829459/diff/1/tests/corelib/math_tes...
tests/corelib/math_test.dart:9: #import('dart:math', prefix: 'math');
On 2012/08/22 07:37:53, ajohnsen wrote:
> Should we remove this file entirely? It's not part of corelib anymore.

We should probably move these files to the tests/lib/math directory. I will do
that.

Powered by Google App Engine
This is Rietveld 408576698