Chromium Code Reviews

Issue 2858353003: Move Dart versions of math.min() and math.max() into VM patch file. (Closed)

Created:
3 years, 7 months ago by Bob Nystrom
Modified:
3 years, 7 months ago
Reviewers:
Lasse Reichstein Nielsen, Jennifer Messerly, sra1
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Move Dart versions of math.min() and math.max() into VM patch file. For DDC and dart2js, we call the corresponding JS function. This is shorter and avoids a strong mode type error in the Dart implementation. R=jmesserly@google.com, lrn@google.com Committed: https://github.com/dart-lang/sdk/commit/4145a495033413054e16a32ef2689e69b02182e3

Patch Set 1 #

Total comments: 4

Patch Set 2 : Merge branch 'master' into min-max #

Patch Set 3 : Merge branch 'master' into min-max #

Unified diffs Side-by-side diffs Stats (+72 lines, -60 lines)
M pkg/dev_compiler/tool/input_sdk/patch/math_patch.dart View 1 chunk +4 lines, -4 lines 0 comments
M pkg/dev_compiler/tool/sdk_expected_errors.txt View 1 chunk +0 lines, -2 lines 0 comments
M runtime/lib/math_patch.dart View 1 chunk +58 lines, -0 lines 0 comments
M sdk/lib/_internal/js_runtime/lib/math_patch.dart View 1 chunk +8 lines, -0 lines 0 comments
M sdk/lib/math/math.dart View 2 chunks +2 lines, -54 lines 0 comments

Messages

Total messages: 11 (3 generated)
Bob Nystrom
3 years, 7 months ago (2017-05-04 21:49:10 UTC) #2
Jennifer Messerly
lgtm on DDC side
3 years, 7 months ago (2017-05-04 22:13:06 UTC) #3
Lasse Reichstein Nielsen
https://codereview.chromium.org/2858353003/diff/1/sdk/lib/math/math.dart File sdk/lib/math/math.dart (right): https://codereview.chromium.org/2858353003/diff/1/sdk/lib/math/math.dart#newcode78 sdk/lib/math/math.dart:78: external T min<T extends num>(T a, T b); I ...
3 years, 7 months ago (2017-05-05 06:23:25 UTC) #4
Lasse Reichstein Nielsen
But otherwise LGTM
3 years, 7 months ago (2017-05-05 06:23:39 UTC) #5
sra1
https://codereview.chromium.org/2858353003/diff/1/runtime/lib/math_patch.dart File runtime/lib/math_patch.dart (right): https://codereview.chromium.org/2858353003/diff/1/runtime/lib/math_patch.dart#newcode13 runtime/lib/math_patch.dart:13: // return type. Fix this comment to say the ...
3 years, 7 months ago (2017-05-05 07:08:23 UTC) #7
Lasse Reichstein Nielsen
https://codereview.chromium.org/2858353003/diff/1/sdk/lib/_internal/js_runtime/lib/math_patch.dart File sdk/lib/_internal/js_runtime/lib/math_patch.dart (right): https://codereview.chromium.org/2858353003/diff/1/sdk/lib/_internal/js_runtime/lib/math_patch.dart#newcode12 sdk/lib/_internal/js_runtime/lib/math_patch.dart:12: JS('num', r'Math.min(#, #)', checkNum(a), checkNum(b)) as T; It works ...
3 years, 7 months ago (2017-05-05 07:38:51 UTC) #8
Bob Nystrom
On 2017/05/05 06:23:25, Lasse Reichstein Nielsen wrote: > https://codereview.chromium.org/2858353003/diff/1/sdk/lib/math/math.dart > File sdk/lib/math/math.dart (right): > > ...
3 years, 7 months ago (2017-05-05 22:12:17 UTC) #9
Bob Nystrom
3 years, 7 months ago (2017-05-05 22:15:28 UTC) #11
Message was sent while issue was closed.
Committed patchset #3 (id:20001) manually as
4145a495033413054e16a32ef2689e69b02182e3 (presubmit successful).

Powered by Google App Engine