--- parser3/src/include/pa_array.h 2003/03/20 13:09:53 1.57.2.27.2.4 +++ parser3/src/include/pa_array.h 2003/03/26 18:52:49 1.57.2.27.2.7 @@ -8,7 +8,7 @@ #ifndef PA_ARRAY_H #define PA_ARRAY_H -static const char* IDENT_ARRAY_H="$Date: 2003/03/20 13:09:53 $"; +static const char* IDENT_ARRAY_H="$Date: 2003/03/26 18:52:49 $"; // includes @@ -30,10 +30,10 @@ protected: T *felements; // allocated size - int fallocated; + size_t fallocated; // array size - int fused; + size_t fused; public: typedef T element_type; @@ -46,7 +46,7 @@ public: } /// how many items are in Array - int count() const { return fused; } + size_t count() const { return fused; } /// append to array Array& operator += (T src) { if(is_full()) @@ -88,26 +88,33 @@ public: return *this; } + /// quick version of get index-element [use in tight places when sure] + T& unchecked_get(size_t index) const { + return felements[index]; + } + /// get index-element - T& get(int index) const { - if(!(index>=0 && index=0 && index=0 && index=0 && index