Skip to content

Commit 1e569b2

Browse files
committed
Document new custom isEqual method for maps.
1 parent 8265e7a commit 1e569b2

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/Utilities/Testing.hpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,17 @@ namespace GridKit
220220
return fail == 0;
221221
}
222222

223+
/**
224+
* @brief Equatlity comparison between maps with a tolerance for the scalar value
225+
*
226+
* @tparam IdxT
227+
* @tparam RealT
228+
*
229+
* @param[in] std::map<IdxT, RealT> - first map
230+
* @param[in] std::map<IdxT, RealT> - second map
231+
* @param[in] RealT - tolerance
232+
* @return bool - true if the maps are equal; false otherwise
233+
*/
223234
template <typename IdxT = size_t, typename RealT = double>
224235
inline bool isEqual(std::map<IdxT, RealT> a,
225236
std::map<IdxT, RealT> b,

0 commit comments

Comments
 (0)