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

Unified Diff: include/v8.h

Issue 2205203002: Change an output parameter of Maybe<T>::To() from a reference to a pointer (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/cctest/test-api.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/v8.h
diff --git a/include/v8.h b/include/v8.h
index 9a7e95a002cad14d82c1d97473371758e187a6d1..ff8f42f842baec3dc1cb297ccd1f3ea086a81d65 100644
--- a/include/v8.h
+++ b/include/v8.h
@@ -6914,8 +6914,8 @@ class Maybe {
// Will crash if the Maybe<> is nothing.
V8_INLINE T ToChecked() const { return FromJust(); }
- V8_WARN_UNUSED_RESULT V8_INLINE bool To(T& out) const {
- if (V8_LIKELY(IsJust())) out = value_;
+ V8_WARN_UNUSED_RESULT V8_INLINE bool To(T* out) const {
+ if (V8_LIKELY(IsJust())) *out = value_;
return IsJust();
}
« no previous file with comments | « no previous file | test/cctest/test-api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698