Skip to content

Commit

Permalink
I always have compiler problems when using operator[](unsigned) when …
Browse files Browse the repository at this point in the history
…I pass int instead, so I added a note to the comments.
  • Loading branch information
cdunn2001 committed Jun 13, 2007
1 parent 9f8abcb commit f4b7393
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions include/json/value.h
Original file line number Diff line number Diff line change
Expand Up @@ -271,8 +271,12 @@ namespace Json {
/// Access an array element (zero based index ).
/// If the array contains less than index element, then null value are inserted
/// in the array so that its size is index+1.
/// (You may need to say 'value[0u]' to get your compiler to distinguish
/// this from the operator[] which takes a string.)
Value &operator[]( UInt index );
/// Access an array element (zero based index )
/// (You may need to say 'value[0u]' to get your compiler to distinguish
/// this from the operator[] which takes a string.)
const Value &operator[]( UInt index ) const;
/// If the array contains at least index+1 elements, returns the element value,
/// otherwise returns defaultValue.
Expand Down

0 comments on commit f4b7393

Please sign in to comment.