Fix invalid type assumption in GenerateNumberToString().
authorbmeurer@chromium.org <bmeurer@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Tue, 21 Jan 2014 10:35:20 +0000 (10:35 +0000)
committerbmeurer@chromium.org <bmeurer@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Tue, 21 Jan 2014 10:35:20 +0000 (10:35 +0000)
We don't have any type feedback in %_NumberToString(), so it's
a bug to assume Type::Number here.

R=svenpanne@chromium.org

Review URL: https://codereview.chromium.org/143893002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18704 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

src/hydrogen.cc

index 63b6da7..3fb867b 100644 (file)
@@ -10277,7 +10277,7 @@ void HOptimizedGraphBuilder::GenerateNumberToString(CallRuntime* call) {
   ASSERT_EQ(1, call->arguments()->length());
   CHECK_ALIVE(VisitForValue(call->arguments()->at(0)));
   HValue* number = Pop();
-  HValue* result = BuildNumberToString(number, Type::Number(isolate()));
+  HValue* result = BuildNumberToString(number, Type::Any(isolate()));
   return ast_context()->ReturnValue(result);
 }