From 6fc16264ce84610dde6ad744e88202a17d7e7e67 Mon Sep 17 00:00:00 2001 From: Dustin Spicuzza Date: Sun, 21 Jan 2024 13:57:11 -0500 Subject: [PATCH] [ntcore] NetworkTable: Actually use the I parameter for structs (#6280) --- .../main/native/include/networktables/NetworkTable.h | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/ntcore/src/main/native/include/networktables/NetworkTable.h b/ntcore/src/main/native/include/networktables/NetworkTable.h index 1d93c8c738..1008859171 100644 --- a/ntcore/src/main/native/include/networktables/NetworkTable.h +++ b/ntcore/src/main/native/include/networktables/NetworkTable.h @@ -246,24 +246,27 @@ class NetworkTable final { * Gets a raw struct serialized value topic. * * @param name topic name + * @param info optional struct type info * @return Topic */ template requires wpi::StructSerializable - StructTopic GetStructTopic(std::string_view name) const { - return StructTopic{GetTopic(name)}; + StructTopic GetStructTopic(std::string_view name, I... info) const { + return StructTopic{GetTopic(name), std::move(info)...}; } /** * Gets a raw struct serialized array topic. * * @param name topic name + * @param info optional struct type info * @return Topic */ template requires wpi::StructSerializable - StructArrayTopic GetStructArrayTopic(std::string_view name) const { - return StructArrayTopic{GetTopic(name)}; + StructArrayTopic GetStructArrayTopic(std::string_view name, + I... info) const { + return StructArrayTopic{GetTopic(name), std::move(info)...}; } /**