Changeset 1149 for trunk/src/lol/math/vector.h
- Timestamp:
- Mar 2, 2012, 2:00:45 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lol/math/vector.h
r1148 r1149 95 95 inline T const& operator[](int n) const { return *(&this->x + n); } \ 96 96 \ 97 void printf() const; \ 97 /* Visual Studio insists on having an assignment operator. */ \ 98 inline tname<T> const & operator =(tname<T> const &that) \ 99 { \ 100 for (size_t n = 0; n < sizeof(*this) / sizeof(T); n++) \ 101 (*this)[n] = that[n]; \ 102 return *this; \ 103 } \ 98 104 \ 99 105 template<typename U> \ … … 104 110 ret[n] = static_cast<U>((*this)[n]); \ 105 111 return ret; \ 106 } 112 } \ 113 \ 114 void printf() const; 107 115 108 116 /*
Note: See TracChangeset
for help on using the changeset viewer.