Changeset 7268 for code/trunk/src/libraries/util
- Timestamp:
- Aug 30, 2010, 7:34:07 PM (15 years ago)
- Location:
- code/trunk/src/libraries/util
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/libraries/util/MultiType.h
r7266 r7268 272 272 inline ~MultiType() { if (this->value_) { delete this->value_; } } 273 273 274 template <typename V> inline constMultiType& operator=(const V& value) { this->setValue(value); return (*this); } /** @brief Assigns a new value. The value will be converted to the current type of the MultiType. */275 template <typename V> inline constMultiType& operator=(V* value) { this->setValue(value); return (*this); } /** @brief Assigns a pointer. */276 inline constMultiType& operator=(const MultiType& other) { this->setValue(other); return (*this); } /** @brief Assigns the value of the other MultiType and converts it to the current type of the MultiType. */277 inline constMultiType& operator=(MT_Type::Value type) { this->setType(type); return (*this); } /** @brief Resets the value and changes the type. */274 template <typename V> inline MultiType& operator=(const V& value) { this->setValue(value); return (*this); } /** @brief Assigns a new value. The value will be converted to the current type of the MultiType. */ 275 template <typename V> inline MultiType& operator=(V* value) { this->setValue(value); return (*this); } /** @brief Assigns a pointer. */ 276 inline MultiType& operator=(const MultiType& other) { this->setValue(other); return (*this); } /** @brief Assigns the value of the other MultiType and converts it to the current type of the MultiType. */ 277 inline MultiType& operator=(MT_Type::Value type) { this->setType(type); return (*this); } /** @brief Resets the value and changes the type. */ 278 278 279 279 inline bool setValue(const char& value); -
code/trunk/src/libraries/util/mbool.h
r6417 r7268 42 42 { this->value_.memory_ = value.value_.memory_; } 43 43 44 inline constmbool& operator=(bool value)44 inline mbool& operator=(bool value) 45 45 { if (value != this->value_.bool_) { ++this->value_.memory_; } return (*this); } 46 inline constmbool& operator=(const mbool& value)46 inline mbool& operator=(const mbool& value) 47 47 { this->value_.memory_ = value.value_.memory_; return (*this); } 48 48
Note: See TracChangeset
for help on using the changeset viewer.