]> git.saurik.com Git - wxWidgets.git/commitdiff
add operator[] to our wxStringImpl (blind fix for wxMac buildbot build)
authorVadim Zeitlin <vadim@wxwidgets.org>
Wed, 30 Jul 2008 22:11:06 +0000 (22:11 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Wed, 30 Jul 2008 22:11:06 +0000 (22:11 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@54862 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/stringimpl.h

index f3cd17cec2b24cf39164d44feb0e8be061478aae..00d24e22424cba32fd01f294cd131b9bf1703fb8 100644 (file)
@@ -382,9 +382,11 @@ public:
 
   // lib.string.access
     // return the character at position n
+  value_type operator[](size_type n) const { return m_pchData[n]; }
   value_type at(size_type n) const
     { wxASSERT_VALID_INDEX( n ); return m_pchData[n]; }
     // returns the writable character at position n
+  reference operator[](size_type n) { CopyBeforeWrite(); return m_pchData[n]; }
   reference at(size_type n)
   {
     wxASSERT_VALID_INDEX( n );