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

Side by Side Diff: test/cctest/test-func-name-inference.cc

Issue 24169005: remove HEAP from tests (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 3 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 | « test/cctest/test-disasm-x64.cc ('k') | test/cctest/test-global-handles.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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 script_src, 75 script_src,
76 func_pos_str, 76 func_pos_str,
77 0); 77 0);
78 CHECK_NE(0, func_pos); 78 CHECK_NE(0, func_pos);
79 79
80 #ifdef ENABLE_DEBUGGER_SUPPORT 80 #ifdef ENABLE_DEBUGGER_SUPPORT
81 // Obtain SharedFunctionInfo for the function. 81 // Obtain SharedFunctionInfo for the function.
82 isolate->debug()->PrepareForBreakPoints(); 82 isolate->debug()->PrepareForBreakPoints();
83 Object* shared_func_info_ptr = 83 Object* shared_func_info_ptr =
84 isolate->debug()->FindSharedFunctionInfoInScript(i_script, func_pos); 84 isolate->debug()->FindSharedFunctionInfoInScript(i_script, func_pos);
85 CHECK(shared_func_info_ptr != HEAP->undefined_value()); 85 CHECK(shared_func_info_ptr != CcTest::heap()->undefined_value());
86 Handle<SharedFunctionInfo> shared_func_info( 86 Handle<SharedFunctionInfo> shared_func_info(
87 SharedFunctionInfo::cast(shared_func_info_ptr)); 87 SharedFunctionInfo::cast(shared_func_info_ptr));
88 88
89 // Verify inferred function name. 89 // Verify inferred function name.
90 SmartArrayPointer<char> inferred_name = 90 SmartArrayPointer<char> inferred_name =
91 shared_func_info->inferred_name()->ToCString(); 91 shared_func_info->inferred_name()->ToCString();
92 CHECK_EQ(ref_inferred_name, *inferred_name); 92 CHECK_EQ(ref_inferred_name, *inferred_name);
93 #endif // ENABLE_DEBUGGER_SUPPORT 93 #endif // ENABLE_DEBUGGER_SUPPORT
94 } 94 }
95 95
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
475 " };\n" 475 " };\n"
476 " var foo = 10;\n" 476 " var foo = 10;\n"
477 " function f() {\n" 477 " function f() {\n"
478 " return wrapCode();\n" 478 " return wrapCode();\n"
479 " }\n" 479 " }\n"
480 " this.ref = f;\n" 480 " this.ref = f;\n"
481 "})()"); 481 "})()");
482 script->Run(); 482 script->Run();
483 CheckFunctionName(script, "return 2012", ""); 483 CheckFunctionName(script, "return 2012", "");
484 } 484 }
OLDNEW
« no previous file with comments | « test/cctest/test-disasm-x64.cc ('k') | test/cctest/test-global-handles.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698