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

Unified Diff: test/cctest/test-compiler.cc

Issue 27267: Experimental: periodic merge from the bleeding edge branch to the code... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/toiger/
Patch Set: '' Created 11 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/cctest/test-assembler-ia32.cc ('k') | test/cctest/test-disasm-arm.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-compiler.cc
===================================================================
--- test/cctest/test-compiler.cc (revision 1380)
+++ test/cctest/test-compiler.cc (working copy)
@@ -302,3 +302,17 @@
&has_pending_exception);
CHECK(!has_pending_exception);
}
+
+
+// Regression 236. Calling InitLineEnds on a Script with undefined
+// source resulted in crash.
+TEST(Regression236) {
+ InitializeVM();
+ v8::HandleScope scope;
+
+ Handle<Script> script = Factory::NewScript(Factory::empty_string());
+ script->set_source(Heap::undefined_value());
+ CHECK_EQ(-1, script->GetLineNumber(0));
+ CHECK_EQ(-1, script->GetLineNumber(100));
+ CHECK_EQ(-1, script->GetLineNumber(-1));
+}
« no previous file with comments | « test/cctest/test-assembler-ia32.cc ('k') | test/cctest/test-disasm-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698