diff --git a/wpilibNewCommands/src/main/native/cpp/frc2/command/SequentialCommandGroup.cpp b/wpilibNewCommands/src/main/native/cpp/frc2/command/SequentialCommandGroup.cpp index c7f409bfa6..345a415786 100644 --- a/wpilibNewCommands/src/main/native/cpp/frc2/command/SequentialCommandGroup.cpp +++ b/wpilibNewCommands/src/main/native/cpp/frc2/command/SequentialCommandGroup.cpp @@ -76,7 +76,7 @@ void SequentialCommandGroup::AddCommands( } SequentialCommandGroup SequentialCommandGroup::BeforeStarting( - std::function toRun, wpi::ArrayRef requirements) && { + std::function toRun, wpi::span requirements) && { // store all the commands std::vector> tmp; tmp.emplace_back( @@ -97,7 +97,7 @@ SequentialCommandGroup SequentialCommandGroup::BeforeStarting( } SequentialCommandGroup SequentialCommandGroup::AndThen( - std::function toRun, wpi::ArrayRef requirements) && { + std::function toRun, wpi::span requirements) && { std::vector> tmp; tmp.emplace_back( std::make_unique(std::move(toRun), requirements)); diff --git a/wpilibNewCommands/src/main/native/include/frc2/command/SequentialCommandGroup.h b/wpilibNewCommands/src/main/native/include/frc2/command/SequentialCommandGroup.h index 144f98d86a..d80c07b5f2 100644 --- a/wpilibNewCommands/src/main/native/include/frc2/command/SequentialCommandGroup.h +++ b/wpilibNewCommands/src/main/native/include/frc2/command/SequentialCommandGroup.h @@ -15,6 +15,8 @@ #include #include +#include + #include "frc2/command/CommandGroupBase.h" #include "frc2/command/CommandHelper.h" @@ -86,11 +88,12 @@ class SequentialCommandGroup SequentialCommandGroup BeforeStarting( std::function toRun, - wpi::ArrayRef requirements = {}) && + wpi::span requirements = {}) && override; - SequentialCommandGroup AndThen(std::function toRun, - wpi::ArrayRef requirements = {}) && + SequentialCommandGroup AndThen( + std::function toRun, + wpi::span requirements = {}) && override; private: