title: C++: Convenient way to access operator[] from within class?
body: <p>I have a C++ class that overloads <code>operator[]</code>, the array subscript/brackets operator.  This is awfully convenient outside of my class, where I can write <code>foo[bar</code>].  However, I can't figure out how to use this notation when I'm implementing methods <em>inside</em> my class.</p>
  
  <p>I know I can write <code>operator[](bar)</code> or <code>this-&gt;operator[](bar)</code> but those are fairly unwieldy and take away a lot of the convenience of the operator in the first place.  (I also know I can just add a new method that calls the operator.)  Is there a way I can write <code>this[bar]</code> or <code>this-&gt;[bar]</code> or something similarly nice?</p>