Browse Source

fix PTA_Vertex::set_element()

David Rose 21 years ago
parent
commit
22a4972fe0
2 changed files with 4 additions and 4 deletions
  1. 2 2
      panda/src/express/pointerToArray.I
  2. 2 2
      panda/src/express/pointerToArray.h

+ 2 - 2
panda/src/express/pointerToArray.I

@@ -322,7 +322,7 @@ operator [](int n) const {
 //               a confusion with the pointer typecast operator.
 ////////////////////////////////////////////////////////////////////
 template<class Element>
-INLINE TYPENAME PointerToArray<Element>::const_reference PointerToArray<Element>::
+INLINE const Element &PointerToArray<Element>::
 get_element(size_type n) const {
   return (*this)[n];
 }
@@ -338,7 +338,7 @@ get_element(size_type n) const {
 ////////////////////////////////////////////////////////////////////
 template<class Element>
 INLINE void PointerToArray<Element>::
-set_element(size_type n, const_reference value) {
+set_element(size_type n, const Element &value) {
   nassertv(n < ((To *)_void_ptr)->size());
   (*this)[n] = value;
 }

+ 2 - 2
panda/src/express/pointerToArray.h

@@ -153,8 +153,8 @@ PUBLISHED:
   INLINE reference operator [](size_type n) const;
   INLINE reference operator [](int n) const;
 #endif
-  INLINE const_reference get_element(size_type n) const;
-  INLINE void set_element(size_type n, const_reference value);
+  INLINE const Element &get_element(size_type n) const;
+  INLINE void set_element(size_type n, const Element &value);
 
   INLINE void push_back(const Element &x);
   INLINE void pop_back();