Skip to content

Conversation

@evelez7
Copy link
Member

@evelez7 evelez7 commented Nov 20, 2025

No description provided.

@evelez7 evelez7 marked this pull request as ready for review November 20, 2025 06:53
Copy link
Member Author

evelez7 commented Nov 20, 2025

This stack of pull requests is managed by Graphite. Learn more about stacking.

@llvmbot
Copy link
Member

llvmbot commented Nov 20, 2025

@llvm/pr-subscribers-llvm-support

Author: Erick Velez (evelez7)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/168835.diff

1 Files Affected:

  • (modified) llvm/include/llvm/Support/JSON.h (+2)
diff --git a/llvm/include/llvm/Support/JSON.h b/llvm/include/llvm/Support/JSON.h
index 37baa7b45e4eb..a58332c912942 100644
--- a/llvm/include/llvm/Support/JSON.h
+++ b/llvm/include/llvm/Support/JSON.h
@@ -205,6 +205,7 @@ class Array {
   iterator insert(const_iterator P, Value &&E);
   template <typename It> iterator insert(const_iterator P, It A, It Z);
   template <typename... Args> iterator emplace(const_iterator P, Args &&...A);
+  iterator erase(const_iterator P);
 
   friend bool operator==(const Array &L, const Array &R);
 };
@@ -579,6 +580,7 @@ template <typename... Args>
 inline Array::iterator Array::emplace(const_iterator P, Args &&...A) {
   return V.emplace(P, std::forward<Args>(A)...);
 }
+inline Array::iterator Array::erase(const_iterator P) { return V.erase(P); }
 inline bool operator==(const Array &L, const Array &R) { return L.V == R.V; }
 
 /// ObjectKey is a used to capture keys in Object. Like Value but:

@evelez7 evelez7 assigned nikic, kuhar and dwblaikie and unassigned nikic, kuhar and dwblaikie Nov 20, 2025
@evelez7 evelez7 requested review from dwblaikie, kuhar and nikic November 20, 2025 07:00
@github-actions
Copy link

🐧 Linux x64 Test Results

  • 186417 tests passed
  • 4863 tests skipped

@evelez7 evelez7 changed the title [Support] add vector::erase to JSON::Array [Support] Add vector::erase to JSON::Array Nov 20, 2025
@evelez7 evelez7 merged commit 155a7d8 into main Nov 20, 2025
14 checks passed
@evelez7 evelez7 deleted the users/evelez7/support-json-vector-erase branch November 20, 2025 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants