Fix a lot of ref issues reagrding extarction, rvalueness and proper use of temporary memory.
This commit is contained in:
parent
d5c41bf43e
commit
379d77ebef
50 changed files with 2945 additions and 1397 deletions
|
|
@ -300,10 +300,37 @@ CLASSNAME& CLASSNAME::operator/=(TYPE s)
|
|||
return *this;
|
||||
}
|
||||
|
||||
//==================================================================================================
|
||||
// Static functions
|
||||
//==================================================================================================
|
||||
//==============================================================================
|
||||
// Generators functions
|
||||
//==============================================================================
|
||||
void CLASSNAME::setOnes(std::size_t rows, std::size_t cols)
|
||||
{
|
||||
storage_->assign(payload::data_type::Ones(rows, cols).eval());
|
||||
}
|
||||
|
||||
void CLASSNAME::setZero(std::size_t rows, std::size_t cols)
|
||||
{
|
||||
storage_->assign(payload::data_type::Zero(rows, cols).eval());
|
||||
}
|
||||
|
||||
void CLASSNAME::setConstant(std::size_t rows, std::size_t cols, TYPE value)
|
||||
{
|
||||
storage_->assign(payload::data_type::Constant(rows, cols, value).eval());
|
||||
}
|
||||
|
||||
void CLASSNAME::setRandom(std::size_t rows, std::size_t cols)
|
||||
{
|
||||
storage_->assign(payload::data_type::Random(rows, cols).eval());
|
||||
}
|
||||
|
||||
void CLASSNAME::setIdentity(std::size_t rows, std::size_t cols)
|
||||
{
|
||||
storage_->assign(payload::data_type::Identity(rows, cols).eval());
|
||||
}
|
||||
|
||||
//==============================================================================
|
||||
// Static functions
|
||||
//==============================================================================
|
||||
CLASSNAME CLASSNAME::Ones(std::size_t rows, std::size_t cols)
|
||||
{
|
||||
CLASSNAME m;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue