From 9b34069a3b2bb0fa3630dbec047511282fcdd802 Mon Sep 17 00:00:00 2001 From: Benoit Blanchon Date: Mon, 25 Sep 2023 15:16:41 +0200 Subject: [PATCH] Remove obsolete comments --- src/ArduinoJson/Array/JsonArray.hpp | 3 --- src/ArduinoJson/Document/JsonDocument.hpp | 3 --- src/ArduinoJson/Object/JsonObject.hpp | 4 ---- src/ArduinoJson/Variant/VariantRefBase.hpp | 7 ------- 4 files changed, 17 deletions(-) diff --git a/src/ArduinoJson/Array/JsonArray.hpp b/src/ArduinoJson/Array/JsonArray.hpp index 1046f111..7c2303bf 100644 --- a/src/ArduinoJson/Array/JsonArray.hpp +++ b/src/ArduinoJson/Array/JsonArray.hpp @@ -104,21 +104,18 @@ class JsonArray : public detail::VariantOperators { } // Removes the element at the specified iterator. - // ⚠️ Doesn't release the memory associated with the removed element. // https://arduinojson.org/v7/api/jsonarray/remove/ FORCE_INLINE void remove(iterator it) const { detail::ArrayData::remove(data_, it.iterator_, resources_); } // Removes the element at the specified index. - // ⚠️ Doesn't release the memory associated with the removed element. // https://arduinojson.org/v7/api/jsonarray/remove/ FORCE_INLINE void remove(size_t index) const { detail::ArrayData::removeElement(data_, index, resources_); } // Removes all the elements of the array. - // ⚠️ Doesn't release the memory associated with the removed elements. // https://arduinojson.org/v7/api/jsonarray/clear/ void clear() const { detail::ArrayData::clear(data_, resources_); diff --git a/src/ArduinoJson/Document/JsonDocument.hpp b/src/ArduinoJson/Document/JsonDocument.hpp index 3a297045..ebce0628 100644 --- a/src/ArduinoJson/Document/JsonDocument.hpp +++ b/src/ArduinoJson/Document/JsonDocument.hpp @@ -251,14 +251,12 @@ class JsonDocument : public detail::VariantOperators { } // Removes an element of the root array. - // ⚠️ Doesn't release the memory associated with the removed element. // https://arduinojson.org/v7/api/jsondocument/remove/ FORCE_INLINE void remove(size_t index) { detail::VariantData::removeElement(getData(), index, getResourceManager()); } // Removes a member of the root object. - // ⚠️ Doesn't release the memory associated with the removed element. // https://arduinojson.org/v7/api/jsondocument/remove/ template FORCE_INLINE typename detail::enable_if::value>::type @@ -268,7 +266,6 @@ class JsonDocument : public detail::VariantOperators { } // Removes a member of the root object. - // ⚠️ Doesn't release the memory associated with the removed element. // https://arduinojson.org/v7/api/jsondocument/remove/ template FORCE_INLINE diff --git a/src/ArduinoJson/Object/JsonObject.hpp b/src/ArduinoJson/Object/JsonObject.hpp index ce04b783..c5ac3305 100644 --- a/src/ArduinoJson/Object/JsonObject.hpp +++ b/src/ArduinoJson/Object/JsonObject.hpp @@ -80,7 +80,6 @@ class JsonObject : public detail::VariantOperators { } // Removes all the members of the object. - // ⚠️ Doesn't release the memory associated with the removed members. // https://arduinojson.org/v7/api/jsonobject/clear/ void clear() const { detail::ObjectData::clear(data_, resources_); @@ -122,14 +121,12 @@ class JsonObject : public detail::VariantOperators { } // Removes the member at the specified iterator. - // ⚠️ Doesn't release the memory associated with the removed member. // https://arduinojson.org/v7/api/jsonobject/remove/ FORCE_INLINE void remove(iterator it) const { detail::ObjectData::remove(data_, it.iterator_, resources_); } // Removes the member with the specified key. - // ⚠️ Doesn't release the memory associated with the removed member. // https://arduinojson.org/v7/api/jsonobject/remove/ template FORCE_INLINE void remove(const TString& key) const { @@ -138,7 +135,6 @@ class JsonObject : public detail::VariantOperators { } // Removes the member with the specified key. - // ⚠️ Doesn't release the memory associated with the removed member. // https://arduinojson.org/v7/api/jsonobject/remove/ template FORCE_INLINE void remove(TChar* key) const { diff --git a/src/ArduinoJson/Variant/VariantRefBase.hpp b/src/ArduinoJson/Variant/VariantRefBase.hpp index 97422c1e..2dc95c4e 100644 --- a/src/ArduinoJson/Variant/VariantRefBase.hpp +++ b/src/ArduinoJson/Variant/VariantRefBase.hpp @@ -27,7 +27,6 @@ class VariantRefBase : public VariantTag { public: // Sets the value to null. - // ⚠️ Doesn't release the memory associated with the previous value. // https://arduinojson.org/v7/api/jsonvariant/clear/ FORCE_INLINE void clear() const { VariantData::setNull(getOrCreateData(), getResourceManager()); @@ -67,20 +66,17 @@ class VariantRefBase : public VariantTag { } // Sets the value to an empty array. - // ⚠️ Doesn't release the memory associated with the previous value. // https://arduinojson.org/v7/api/jsonvariant/to/ template typename enable_if::value, JsonArray>::type to() const; // Sets the value to an empty object. - // ⚠️ Doesn't release the memory associated with the previous value. // https://arduinojson.org/v7/api/jsonvariant/to/ template typename enable_if::value, JsonObject>::type to() const; // Sets the value to null. - // ⚠️ Doesn't release the memory associated with the previous value. // https://arduinojson.org/v7/api/jsonvariant/to/ template typename enable_if::value, JsonVariant>::type to() @@ -165,14 +161,12 @@ class VariantRefBase : public VariantTag { } // Removes an element of the array. - // ⚠️ Doesn't release the memory associated with the removed element. // https://arduinojson.org/v7/api/jsonvariant/remove/ FORCE_INLINE void remove(size_t index) const { VariantData::removeElement(getData(), index, getResourceManager()); } // Removes a member of the object. - // ⚠️ Doesn't release the memory associated with the removed element. // https://arduinojson.org/v7/api/jsonvariant/remove/ template FORCE_INLINE typename enable_if::value>::type remove( @@ -182,7 +176,6 @@ class VariantRefBase : public VariantTag { } // Removes a member of the object. - // ⚠️ Doesn't release the memory associated with the removed element. // https://arduinojson.org/v7/api/jsonvariant/remove/ template FORCE_INLINE typename enable_if::value>::type remove(