Skip to content

Commit

Permalink
Remove obsolete comments
Browse files Browse the repository at this point in the history
  • Loading branch information
bblanchon committed Sep 25, 2023
1 parent 30ea01b commit 9b34069
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 17 deletions.
3 changes: 0 additions & 3 deletions src/ArduinoJson/Array/JsonArray.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -104,21 +104,18 @@ class JsonArray : public detail::VariantOperators<JsonArray> {
}

// 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_);
Expand Down
3 changes: 0 additions & 3 deletions src/ArduinoJson/Document/JsonDocument.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -251,14 +251,12 @@ class JsonDocument : public detail::VariantOperators<const JsonDocument&> {
}

// 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 <typename TChar>
FORCE_INLINE typename detail::enable_if<detail::IsString<TChar*>::value>::type
Expand All @@ -268,7 +266,6 @@ class JsonDocument : public detail::VariantOperators<const JsonDocument&> {
}

// 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 <typename TString>
FORCE_INLINE
Expand Down
4 changes: 0 additions & 4 deletions src/ArduinoJson/Object/JsonObject.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ class JsonObject : public detail::VariantOperators<JsonObject> {
}

// 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_);
Expand Down Expand Up @@ -122,14 +121,12 @@ class JsonObject : public detail::VariantOperators<JsonObject> {
}

// 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 <typename TString>
FORCE_INLINE void remove(const TString& key) const {
Expand All @@ -138,7 +135,6 @@ class JsonObject : public detail::VariantOperators<JsonObject> {
}

// 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 <typename TChar>
FORCE_INLINE void remove(TChar* key) const {
Expand Down
7 changes: 0 additions & 7 deletions src/ArduinoJson/Variant/VariantRefBase.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -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());
Expand Down Expand Up @@ -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 T>
typename enable_if<is_same<T, JsonArray>::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 T>
typename enable_if<is_same<T, JsonObject>::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 T>
typename enable_if<is_same<T, JsonVariant>::value, JsonVariant>::type to()
Expand Down Expand Up @@ -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 <typename TChar>
FORCE_INLINE typename enable_if<IsString<TChar*>::value>::type remove(
Expand All @@ -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 <typename TString>
FORCE_INLINE typename enable_if<IsString<TString>::value>::type remove(
Expand Down

0 comments on commit 9b34069

Please sign in to comment.