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

Unified Diff: test/cctest/cctest.h

Issue 1213783002: Put getter functions on Script line-endings objects (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix test Created 5 years, 6 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 | « src/messages.js ('k') | test/cctest/test-debug.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/cctest.h
diff --git a/test/cctest/cctest.h b/test/cctest/cctest.h
index 73baa7656ec2ea952c524230e401f56ecf1bbd63..cc9edc801f5e268b17476178cea243b51cb2495b 100644
--- a/test/cctest/cctest.h
+++ b/test/cctest/cctest.h
@@ -398,6 +398,13 @@ static inline v8::Local<v8::Value> CompileRun(const char* source) {
}
+// Helper functions that compile and run the source.
+static inline v8::MaybeLocal<v8::Value> CompileRun(
+ v8::Local<v8::Context> context, const char* source) {
+ return v8::Script::Compile(v8_str(source))->Run(context);
+}
+
+
// Compiles source as an ES6 module.
static inline v8::Local<v8::Value> CompileRunModule(const char* source) {
v8::ScriptCompiler::Source script_source(v8_str(source));
« no previous file with comments | « src/messages.js ('k') | test/cctest/test-debug.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698