Change AMFArray getters to use Templates and fix CI halting when one matrix fails (#796)

* Change AMFArray getters to use Templates

Move Template definition to header

* Add more tests

Add tests for casting to wrong template type
Add tests for going out of bounds in the array.

* Try continue-on-error

* Update build-and-test.yml

* Try continue-on-error

Update build-and-test.yml

* change version

* Update CMakeMariaDBLists.txt

Update CMakeMariaDBLists.txt
This commit is contained in:
David Markowitz
2022-10-30 13:06:05 -07:00
committed by GitHub
parent 906887bda9
commit 89fb66c4a9
5 changed files with 111 additions and 57 deletions

View File

@@ -58,16 +58,6 @@ void AMFArrayValue::RemoveValue(const std::string& key) {
}
}
// AMFArray Find Value
AMFValue* AMFArrayValue::FindValue(const std::string& key) {
_AMFArrayMap_::iterator it = this->associative.find(key);
if (it != this->associative.end()) {
return it->second;
}
return nullptr;
}
// AMFArray Get Associative Iterator Begin
_AMFArrayMap_::iterator AMFArrayValue::GetAssociativeIteratorValueBegin() {
return this->associative.begin();
@@ -93,11 +83,6 @@ uint32_t AMFArrayValue::GetDenseValueSize() {
return (uint32_t)this->dense.size();
}
// AMFArray Get value at index in Dense List
AMFValue* AMFArrayValue::GetValueAt(uint32_t index) {
return this->dense.at(index);
}
// AMFArray Get Dense Iterator Begin
_AMFArrayList_::iterator AMFArrayValue::GetDenseIteratorBegin() {
return this->dense.begin();