OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 // Patch file for dart:math library. | 5 // Patch file for dart:math library. |
6 import 'dart:_foreign_helper' show JS; | 6 import 'dart:_foreign_helper' show JS; |
7 import 'dart:_js_helper' show patch, checkNum; | 7 import 'dart:_js_helper' show patch, checkNum; |
8 | 8 |
9 @patch | 9 @patch |
10 double sqrt(num x) | 10 double sqrt(num x) |
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
229 _nextState(); | 229 _nextState(); |
230 int bits27 = _lo & ((1 << 27) - 1); | 230 int bits27 = _lo & ((1 << 27) - 1); |
231 return (bits26 * _POW2_27_D + bits27) / _POW2_53_D; | 231 return (bits26 * _POW2_27_D + bits27) / _POW2_53_D; |
232 } | 232 } |
233 | 233 |
234 bool nextBool() { | 234 bool nextBool() { |
235 _nextState(); | 235 _nextState(); |
236 return (_lo & 1) == 0; | 236 return (_lo & 1) == 0; |
237 } | 237 } |
238 } | 238 } |
OLD | NEW |