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

Side by Side Diff: test/cctest/test-api.cc

Issue 160267: There's seems to be an issue with 0/0 on ARM, which I'll... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2007-2008 the V8 project authors. All rights reserved. 1 // Copyright 2007-2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 7626 matching lines...) Expand 10 before | Expand all | Expand 10 after
7637 CHECK_EQ(0, result->Int32Value()); 7637 CHECK_EQ(0, result->Int32Value());
7638 CHECK_EQ(0, i::Smi::cast(jsobj->GetElement(7))->value()); 7638 CHECK_EQ(0, i::Smi::cast(jsobj->GetElement(7))->value());
7639 7639
7640 result = CompileRun("for (var i = 0; i < 8; i++) {" 7640 result = CompileRun("for (var i = 0; i < 8; i++) {"
7641 " pixels[6] = '2.3';" 7641 " pixels[6] = '2.3';"
7642 "}" 7642 "}"
7643 "pixels[6];"); 7643 "pixels[6];");
7644 CHECK_EQ(2, result->Int32Value()); 7644 CHECK_EQ(2, result->Int32Value());
7645 CHECK_EQ(2, i::Smi::cast(jsobj->GetElement(6))->value()); 7645 CHECK_EQ(2, i::Smi::cast(jsobj->GetElement(6))->value());
7646 7646
7647 result = CompileRun("var nan = 0/0;" 7647 result = CompileRun("for (var i = 0; i < 8; i++) {"
7648 "for (var i = 0; i < 8; i++) {" 7648 " pixels[5] = NaN;"
7649 " pixels[5] = nan;"
7650 "}" 7649 "}"
7651 "pixels[5];"); 7650 "pixels[5];");
7652 CHECK_EQ(0, result->Int32Value()); 7651 CHECK_EQ(0, result->Int32Value());
7653 CHECK_EQ(0, i::Smi::cast(jsobj->GetElement(5))->value()); 7652 CHECK_EQ(0, i::Smi::cast(jsobj->GetElement(5))->value());
7654 7653
7655 result = CompileRun("pixels[3] = 33;" 7654 result = CompileRun("pixels[3] = 33;"
7656 "delete pixels[3];" 7655 "delete pixels[3];"
7657 "pixels[3];"); 7656 "pixels[3];");
7658 CHECK_EQ(33, result->Int32Value()); 7657 CHECK_EQ(33, result->Int32Value());
7659 7658
(...skipping 11 matching lines...) Expand all
7671 7670
7672 result = CompileRun("pixels[1] = 23;" 7671 result = CompileRun("pixels[1] = 23;"
7673 "pixels.__proto__ = [];" 7672 "pixels.__proto__ = [];"
7674 "js_array.__proto__ = pixels;" 7673 "js_array.__proto__ = pixels;"
7675 "js_array.concat(pixels);"); 7674 "js_array.concat(pixels);");
7676 CHECK_EQ(77, v8::Object::Cast(*result)->Get(v8_str("0"))->Int32Value()); 7675 CHECK_EQ(77, v8::Object::Cast(*result)->Get(v8_str("0"))->Int32Value());
7677 CHECK_EQ(23, v8::Object::Cast(*result)->Get(v8_str("1"))->Int32Value()); 7676 CHECK_EQ(23, v8::Object::Cast(*result)->Get(v8_str("1"))->Int32Value());
7678 7677
7679 free(pixel_data); 7678 free(pixel_data);
7680 } 7679 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698