From 030ac1fff41d19fd16929c0f46cdb0b9a1a80bbd Mon Sep 17 00:00:00 2001 From: Kenneth Moreland Date: Thu, 16 Dec 2021 08:20:42 -0700 Subject: [PATCH] Fix some copy/paste errors with comments and variable names --- vtkm/cont/UncertainCellSet.h | 18 +++++++++--------- vtkm/cont/UnknownCellSet.cxx | 2 +- vtkm/cont/UnknownCellSet.h | 4 ++-- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/vtkm/cont/UncertainCellSet.h b/vtkm/cont/UncertainCellSet.h index af58b3230..ec9f97d95 100644 --- a/vtkm/cont/UncertainCellSet.h +++ b/vtkm/cont/UncertainCellSet.h @@ -69,15 +69,15 @@ public: /// \brief Create a new cell set of the same type as this. /// - /// This method creates a new array that is the same type as this one and + /// This method creates a new cell set that is the same type as this one and /// returns a new `UncertainCellSet` for it. /// VTKM_CONT Thisclass NewInstance() const { return Thisclass(this->Superclass::NewInstance()); } - /// \brief Call a functor using the underlying array type. + /// \brief Call a functor using the underlying cell set type. /// - /// `CastAndCall` attempts to cast the held array to a specific value type, - /// and then calls the given functor with the cast array. + /// `CastAndCall` attempts to cast the held cell set to a specific type, + /// and then calls the given functor with the cast cell set. /// template VTKM_CONT void CastAndCall(Functor&& functor, Args&&... args) const @@ -87,7 +87,7 @@ public: } }; -// Defined here to avoid circular dependencies between UnknownArrayHandle and UncertainArrayHandle. +// Defined here to avoid circular dependencies between UnknownCellSet and UncertainCellSet. template VTKM_CONT vtkm::cont::UncertainCellSet UnknownCellSet::ResetCellSetList( NewCellSetList) const @@ -154,16 +154,16 @@ struct UncertainCellSetDeserializeFunctor { template void operator()(CellSetType, - vtkm::cont::UnknownCellSet& unknownArray, + vtkm::cont::UnknownCellSet& unknownCellSet, const std::string& typeString, bool& success, BinaryBuffer& bb) const { if (!success && (typeString == vtkm::cont::SerializableTypeString::Get())) { - CellSetType knownArray; - vtkmdiy::load(bb, knownArray); - unknownArray = knownArray; + CellSetType knownCellSet; + vtkmdiy::load(bb, knownCellSet); + unknownCellSet = knownCellSet; success = true; } } diff --git a/vtkm/cont/UnknownCellSet.cxx b/vtkm/cont/UnknownCellSet.cxx index 4a2c70928..c331eb5cc 100644 --- a/vtkm/cont/UnknownCellSet.cxx +++ b/vtkm/cont/UnknownCellSet.cxx @@ -67,7 +67,7 @@ namespace internal void ThrowCastAndCallException(const vtkm::cont::UnknownCellSet& ref, const std::type_info& type) { std::ostringstream out; - out << "Could not find appropriate cast for array in CastAndCall.\n" + out << "Could not find appropriate cast for cell set in CastAndCall.\n" "CellSet: "; ref.PrintSummary(out); out << "TypeList: " << vtkm::cont::TypeToString(type) << "\n"; diff --git a/vtkm/cont/UnknownCellSet.h b/vtkm/cont/UnknownCellSet.h index 02007299a..14414be99 100644 --- a/vtkm/cont/UnknownCellSet.h +++ b/vtkm/cont/UnknownCellSet.h @@ -95,7 +95,7 @@ public: /// VTKM_CONT UnknownCellSet NewInstance() const; - /// \brief Returns the name of the cell set type stored in the array. + /// \brief Returns the name of the cell set type stored in this class. /// /// Returns an empty string if no cell set is stored. /// @@ -305,7 +305,7 @@ VTKM_CONT void UnknownCellSet::CastAndCallForTypes(Functor&& functor, Args&&... // vtkm::cont::UnknownCellSet and the arguments of the functor do not match those // being passed. This is often because it is calling the functor with a CellSet // type that was not expected. Either add overloads to the functor to accept all - // possible array types or constrain the types tried for the CastAndCall. + // possible cell set types or constrain the types tried for the CastAndCall. functor(cellSet, args...); } },