diff --git a/ntcore/src/main/native/include/networktables/NetworkTable.h b/ntcore/src/main/native/include/networktables/NetworkTable.h index e2d14212ba..1d93c8c738 100644 --- a/ntcore/src/main/native/include/networktables/NetworkTable.h +++ b/ntcore/src/main/native/include/networktables/NetworkTable.h @@ -248,9 +248,10 @@ class NetworkTable final { * @param name topic name * @return Topic */ - template - StructTopic GetStructTopic(std::string_view name) const { - return StructTopic{GetTopic(name)}; + template + requires wpi::StructSerializable + StructTopic GetStructTopic(std::string_view name) const { + return StructTopic{GetTopic(name)}; } /** @@ -259,9 +260,10 @@ class NetworkTable final { * @param name topic name * @return Topic */ - template - StructArrayTopic GetStructArrayTopic(std::string_view name) const { - return StructArrayTopic{GetTopic(name)}; + template + requires wpi::StructSerializable + StructArrayTopic GetStructArrayTopic(std::string_view name) const { + return StructArrayTopic{GetTopic(name)}; } /**