UniquePointer and UniqeArray ready to use

All compile errors fixed.
Tested against Visual Leak detector. No leak detected!
This commit is contained in:
Dander7BD 2013-11-13 14:48:24 +01:00
parent fa43650439
commit 893e6427a5
1 changed files with 3 additions and 3 deletions

View File

@ -124,7 +124,7 @@ namespace Utility
}
template<typename Type>
UniqueArray<Type> & UniqueArray<Type>::operator = ( const UniquePointer<Type> &donor )
UniqueArray<Type> & UniqueArray<Type>::operator = ( const UniqueArray<Type> &donor )
{
SafeDeleteArray( this->ownedArray );
this->ownedArray = donor.ownedInstance;
@ -132,13 +132,13 @@ namespace Utility
}
template<typename Type> template<typename Index>
template<typename Index> Type & UniqueArray<Type>::operator [] ( Index i )
Type & UniqueArray<Type>::operator [] ( Index i )
{
return this->ownedArray[i];
}
template<typename Type> template<typename Index>
template<typename Index> const Type & UniqueArray<Type>::operator [] ( Index i ) const
const Type & UniqueArray<Type>::operator [] ( Index i ) const
{
return this->ownedArray[i];
}