| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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 #include <math.h> | 5 #include <math.h> |
| 6 | 6 |
| 7 #include "vm/bootstrap_natives.h" | 7 #include "vm/bootstrap_natives.h" |
| 8 | 8 |
| 9 #include "vm/bigint_operations.h" | 9 #include "vm/bigint_operations.h" |
| 10 #include "vm/code_generator.h" // DartModulo. | 10 #include "vm/code_generator.h" // DartModulo. |
| (...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 | 264 |
| 265 DEFINE_NATIVE_ENTRY(Double_getIsNaN, 1) { | 265 DEFINE_NATIVE_ENTRY(Double_getIsNaN, 1) { |
| 266 const Double& arg = Double::CheckedHandle(arguments->NativeArgAt(0)); | 266 const Double& arg = Double::CheckedHandle(arguments->NativeArgAt(0)); |
| 267 return Bool::Get(isnan(arg.value())).raw(); | 267 return Bool::Get(isnan(arg.value())).raw(); |
| 268 } | 268 } |
| 269 | 269 |
| 270 | 270 |
| 271 DEFINE_NATIVE_ENTRY(Double_getIsNegative, 1) { | 271 DEFINE_NATIVE_ENTRY(Double_getIsNegative, 1) { |
| 272 const Double& arg = Double::CheckedHandle(arguments->NativeArgAt(0)); | 272 const Double& arg = Double::CheckedHandle(arguments->NativeArgAt(0)); |
| 273 // Include negative zero, infinity. | 273 // Include negative zero, infinity. |
| 274 return Bool::Get(signbit(arg.value()) && !isnan(arg.value())).raw(); | 274 return Bool::Get(arg.IsNegative()).raw(); |
| 275 } | 275 } |
| 276 | 276 |
| 277 // Add here only functions using/referring to old-style casts. | 277 // Add here only functions using/referring to old-style casts. |
| 278 | 278 |
| 279 } // namespace dart | 279 } // namespace dart |
| OLD | NEW |