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

Unified Diff: include/v8.h

Issue 199043: Const Correctness for String::Value (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « AUTHORS ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/v8.h
===================================================================
--- include/v8.h (Revision 2827)
+++ include/v8.h (Arbeitskopie)
@@ -979,8 +979,9 @@
public:
explicit Utf8Value(Handle<v8::Value> obj);
~Utf8Value();
- char* operator*() const { return str_; }
- int length() { return length_; }
+ char* operator*() { return str_; }
+ const char* operator*() const { return str_; }
+ int length() const { return length_; }
private:
char* str_;
int length_;
@@ -1001,8 +1002,9 @@
public:
explicit AsciiValue(Handle<v8::Value> obj);
~AsciiValue();
- char* operator*() const { return str_; }
- int length() { return length_; }
+ char* operator*() { return str_; }
+ const char* operator*() const { return str_; }
+ int length() const { return length_; }
private:
char* str_;
int length_;
@@ -1022,8 +1024,9 @@
public:
explicit Value(Handle<v8::Value> obj);
~Value();
- uint16_t* operator*() const { return str_; }
- int length() { return length_; }
+ uint16_t* operator*() { return str_; }
+ const uint16_t* operator*() const { return str_; }
+ int length() const { return length_; }
private:
uint16_t* str_;
int length_;
« no previous file with comments | « AUTHORS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698