1
0
Fork 0

Implement copying/moving constructors of InputAqlItemRow (#10165)

This commit is contained in:
Tobias Gödderz 2019-10-04 17:46:08 +02:00 committed by Jan
parent 4ec4218213
commit 8603ceb995
2 changed files with 9 additions and 4 deletions

View File

@ -254,7 +254,12 @@ void InputAqlItemRow::toVelocyPack(transaction::Methods* trx, VPackBuilder& resu
InputAqlItemRow::InputAqlItemRow(CreateInvalidInputRowHint)
: _block(nullptr), _baseIndex(0) {}
InputAqlItemRow::InputAqlItemRow(SharedAqlItemBlockPtr block, size_t baseIndex)
InputAqlItemRow::InputAqlItemRow(SharedAqlItemBlockPtr const& block, size_t baseIndex)
: _block(block), _baseIndex(baseIndex) {
TRI_ASSERT(_block != nullptr);
}
InputAqlItemRow::InputAqlItemRow(SharedAqlItemBlockPtr&& block, size_t baseIndex) noexcept
: _block(std::move(block)), _baseIndex(baseIndex) {
TRI_ASSERT(_block != nullptr);
}

View File

@ -67,9 +67,9 @@ class InputAqlItemRow {
// The default constructor contains an invalid item row
explicit InputAqlItemRow(CreateInvalidInputRowHint);
InputAqlItemRow(
// cppcheck-suppress passedByValue
SharedAqlItemBlockPtr block, size_t baseIndex);
InputAqlItemRow(SharedAqlItemBlockPtr const& block, size_t baseIndex);
InputAqlItemRow(SharedAqlItemBlockPtr&& block, size_t baseIndex) noexcept;
/**
* @brief Get a reference to the value of the given Variable Nr