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

Unified Diff: src/api.cc

Issue 71373003: Fix warnings (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 1 month 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 | « include/v8.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/api.cc
diff --git a/src/api.cc b/src/api.cc
index e55e0aa08570c0e57978a16e411f13faad0f38e0..65e73450239c352381676bedb560b332761ef3cd 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -3192,8 +3192,8 @@ bool v8::Object::ForceSet(v8::Handle<Value> key,
bool v8::Object::SetPrivate(v8::Handle<Private> key, v8::Handle<Value> value) {
- v8::Handle<Value>* key_as_value = reinterpret_cast<v8::Handle<Value>*>(&key);
- return Set(*key_as_value, value, DontEnum);
+ return Set(v8::Handle<Value>(reinterpret_cast<Value*>(*key)),
+ value, DontEnum);
}
@@ -3249,8 +3249,7 @@ Local<Value> v8::Object::Get(uint32_t index) {
Local<Value> v8::Object::GetPrivate(v8::Handle<Private> key) {
- v8::Handle<Value>* key_as_value = reinterpret_cast<v8::Handle<Value>*>(&key);
- return Get(*key_as_value);
+ return Get(v8::Handle<Value>(reinterpret_cast<Value*>(*key)));
}
@@ -3454,8 +3453,7 @@ bool v8::Object::Delete(v8::Handle<Value> key) {
bool v8::Object::DeletePrivate(v8::Handle<Private> key) {
- v8::Handle<Value>* key_as_value = reinterpret_cast<v8::Handle<Value>*>(&key);
- return Delete(*key_as_value);
+ return Delete(v8::Handle<Value>(reinterpret_cast<Value*>(*key)));
}
@@ -3474,8 +3472,7 @@ bool v8::Object::Has(v8::Handle<Value> key) {
bool v8::Object::HasPrivate(v8::Handle<Private> key) {
- v8::Handle<Value>* key_as_value = reinterpret_cast<v8::Handle<Value>*>(&key);
- return Has(*key_as_value);
+ return Has(v8::Handle<Value>(reinterpret_cast<Value*>(*key)));
}
@@ -6197,9 +6194,7 @@ Local<Private> v8::Private::New(
symbol->set_name(*name);
}
Local<Symbol> result = Utils::ToLocal(symbol);
- v8::Handle<Private>* result_as_private =
- reinterpret_cast<v8::Handle<Private>*>(&result);
- return *result_as_private;
+ return v8::Handle<Private>(reinterpret_cast<Private*>(*result));
}
« no previous file with comments | « include/v8.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698