Fix warnings about uninitalized value

In some functors within Algorithm.h, the functor did not have a
default constructor that initialized its fields. This could in turn
lead to a warning about using it unitialized.
This commit is contained in:
Kenneth Moreland 2018-10-16 16:32:46 -06:00
parent bddad9b386
commit bcbad61002

@ -88,6 +88,11 @@ struct CopySubRangeFunctor
{
bool valid;
CopySubRangeFunctor()
: valid(false)
{
}
template <typename Device, typename... Args>
VTKM_CONT bool operator()(Device, Args&&... args)
{
@ -203,6 +208,11 @@ struct ScanExclusiveFunctor
{
T result;
ScanExclusiveFunctor()
: result(T())
{
}
template <typename Device, typename... Args>
VTKM_CONT bool operator()(Device, Args&&... args)
{