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

Side by Side Diff: src/runtime/runtime-numbers.cc

Issue 864803002: Remove deprecated v8::base::OS::nan_value(). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix invalid test expectation. Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/objects-inl.h ('k') | src/third_party/fdlibm/fdlibm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #include "src/arguments.h" 7 #include "src/arguments.h"
8 #include "src/base/bits.h" 8 #include "src/base/bits.h"
9 #include "src/bootstrapper.h" 9 #include "src/bootstrapper.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 222
223 return *isolate->factory()->NewNumber(value); 223 return *isolate->factory()->NewNumber(value);
224 } 224 }
225 225
226 226
227 RUNTIME_FUNCTION(Runtime_StringParseFloat) { 227 RUNTIME_FUNCTION(Runtime_StringParseFloat) {
228 HandleScope shs(isolate); 228 HandleScope shs(isolate);
229 DCHECK(args.length() == 1); 229 DCHECK(args.length() == 1);
230 CONVERT_ARG_HANDLE_CHECKED(String, subject, 0); 230 CONVERT_ARG_HANDLE_CHECKED(String, subject, 0);
231 231
232 double value = StringToDouble(isolate->unicode_cache(), subject, 232 double value =
233 ALLOW_TRAILING_JUNK, base::OS::nan_value()); 233 StringToDouble(isolate->unicode_cache(), subject, ALLOW_TRAILING_JUNK,
234 std::numeric_limits<double>::quiet_NaN());
234 235
235 return *isolate->factory()->NewNumber(value); 236 return *isolate->factory()->NewNumber(value);
236 } 237 }
237 238
238 239
239 RUNTIME_FUNCTION(Runtime_NumberToStringRT) { 240 RUNTIME_FUNCTION(Runtime_NumberToStringRT) {
240 HandleScope scope(isolate); 241 HandleScope scope(isolate);
241 DCHECK(args.length() == 1); 242 DCHECK(args.length() == 1);
242 CONVERT_NUMBER_ARG_HANDLE_CHECKED(number, 0); 243 CONVERT_NUMBER_ARG_HANDLE_CHECKED(number, 0);
243 244
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
587 588
588 RUNTIME_FUNCTION(RuntimeReference_IsNonNegativeSmi) { 589 RUNTIME_FUNCTION(RuntimeReference_IsNonNegativeSmi) {
589 SealHandleScope shs(isolate); 590 SealHandleScope shs(isolate);
590 DCHECK(args.length() == 1); 591 DCHECK(args.length() == 1);
591 CONVERT_ARG_CHECKED(Object, obj, 0); 592 CONVERT_ARG_CHECKED(Object, obj, 0);
592 return isolate->heap()->ToBoolean(obj->IsSmi() && 593 return isolate->heap()->ToBoolean(obj->IsSmi() &&
593 Smi::cast(obj)->value() >= 0); 594 Smi::cast(obj)->value() >= 0);
594 } 595 }
595 } 596 }
596 } // namespace v8::internal 597 } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/objects-inl.h ('k') | src/third_party/fdlibm/fdlibm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698