summaryrefslogtreecommitdiffstats
path: root/ppapi/shared_impl/var.h
diff options
context:
space:
mode:
authorbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-22 22:15:58 +0000
committerbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-22 22:15:58 +0000
commit28cfaed056451113a72ce00603848f4a6dd616bb (patch)
treec5de865eb7de9ea487b9af79dac9c9d363ba2876 /ppapi/shared_impl/var.h
parentbacf470d2cd46c0d3b145675e471ab9c6976cee8 (diff)
downloadchromium_src-28cfaed056451113a72ce00603848f4a6dd616bb.zip
chromium_src-28cfaed056451113a72ce00603848f4a6dd616bb.tar.gz
chromium_src-28cfaed056451113a72ce00603848f4a6dd616bb.tar.bz2
Don't use a scoped_refptr for StringVar::FromPPVar
This was leftover from a previous design where I thought it would be necessary. It turns out it just made the code ugly and did unnecessary refcounting. Review URL: http://codereview.chromium.org/7621054 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@97751 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi/shared_impl/var.h')
-rw-r--r--ppapi/shared_impl/var.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/ppapi/shared_impl/var.h b/ppapi/shared_impl/var.h
index 1ff42dd..02553bb 100644
--- a/ppapi/shared_impl/var.h
+++ b/ppapi/shared_impl/var.h
@@ -84,7 +84,7 @@ class Var : public base::RefCounted<Var> {
// return StringVar::StringToPPVar(module, my_string);
//
// Converting a PP_Var to a string:
-// scoped_refptr<StringVar> string(StringVar::FromPPVar(var));
+// StringVar* string = StringVar::FromPPVar(var);
// if (!string)
// return false; // Not a string or an invalid var.
// DoSomethingWithTheString(string->value());
@@ -112,7 +112,7 @@ class StringVar : public Var {
// Helper function that converts a PP_Var to a string. This will return NULL
// if the PP_Var is not of string type or the string is invalid.
- static scoped_refptr<StringVar> FromPPVar(PP_Var var);
+ static StringVar* FromPPVar(PP_Var var);
private:
std::string value_;