[svn-r4707]

Purpose:
    Bug fixing
Description:
    H5IdComponent::operator= shouldn't be virtual because the subclass'
    operator= have different type for the rhs argument.  Removed virtual
Platforms tested:
    SunOS 5.7 (arabica)
    IRIX64 (modi4) - only tested that the warnings went away, still working
                        on other configuration problems.
This commit is contained in:
Binh-Minh Ribler 2001-12-12 14:29:14 -05:00
parent 47d88766db
commit fd48265a02
5 changed files with 7 additions and 17 deletions

View File

@ -76,14 +76,6 @@ DataType& DataType::operator=( const DataType& rhs )
return(*this);
}
// Makes a copy of the predefined type and stores the new
// id in the left hand side object.
DataType& DataType::operator=( const PredType& rhs )
{
copy(rhs);
return(*this);
}
// Determines whether two datatypes refer to the same actual datatype.
bool DataType::operator==(const DataType& compared_type ) const
{
@ -108,7 +100,7 @@ bool DataType::operator==(const DataType& compared_type ) const
//{
//}
// Creates a new variable-length datatype - Note: make it inheritance???
// Creates a new variable-length datatype - Note: should use inheritance -
// work in progress
//DataType DataType::vlenCreate( const DataType& base_type )
//{

View File

@ -42,11 +42,8 @@ class DataType : public H5Object {
// Returns a pointer to the current global overflow function.
H5T_overflow_t getOverflow(void) const;
// Assignment operator that takes a predefined type
virtual DataType& operator=( const PredType& rhs );
// Assignment operator
virtual DataType& operator=( const DataType& rhs );
DataType& operator=( const DataType& rhs );
// Determines whether two datatypes are the same.
bool operator==(const DataType& compared_type ) const;

View File

@ -42,7 +42,7 @@ class IdComponent {
bool noReference();
// Assignment operator
virtual IdComponent& operator=( const IdComponent& rhs );
IdComponent& operator=( const IdComponent& rhs );
// Resets this IdComponent instance
//template <class Type>

View File

@ -29,9 +29,10 @@ PredType::PredType( const PredType& original ) : AtomType( original ) {}
// Makes a copy of the predefined type and stores the new
// id in the left hand side object.
DataType& PredType::operator=( const PredType& rhs )
PredType& PredType::operator=( const PredType& rhs )
{
return(DataType::operator=(rhs));
copy(rhs);
return(*this);
}
const PredType PredType::NotAtexit; // only for atexit/global dest. problem

View File

@ -227,7 +227,7 @@ class PredType : public AtomType {
// Makes a copy of the predefined type and stores the new
// id in the left hand side object.
DataType& operator=( const PredType& rhs );
PredType& operator=( const PredType& rhs );
};
#ifndef H5_NO_NAMESPACE
}