From 21d87cc162c983ac44b1882646c329d376d065ba Mon Sep 17 00:00:00 2001 From: mikee47 Date: Sat, 14 Sep 2024 11:34:55 +0100 Subject: [PATCH] Fix build failure on C++20 --- src/include/FlashString/Object.hpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/include/FlashString/Object.hpp b/src/include/FlashString/Object.hpp index e9d69fd..7aaf77d 100644 --- a/src/include/FlashString/Object.hpp +++ b/src/include/FlashString/Object.hpp @@ -103,10 +103,13 @@ template class Object : public ObjectBa using DataPtrType = const ElementType*; using Iterator = ObjectIterator; +// This is precautionary to prevent misuse. No known fix for C++20. +#if __cplusplus < 202002L Object(const Object&) = delete; Object(const Object&&) = delete; Object& operator=(const Object&) = delete; Object& operator=(const Object&&) = delete; +#endif Iterator begin() const {