[clang] [Sema] Keep attribute lists in the order the attributes were parsed (PR #162714)

Saleem Abdulrasool via cfe-commits cfe-commits at lists.llvm.org
Thu Oct 9 14:06:18 PDT 2025


================
@@ -856,19 +856,19 @@ class ParsedAttributesView {
     friend class ParsedAttributesView;
   };
 
-  void addAll(iterator B, iterator E) {
+  void prependAll(iterator B, iterator E) {
----------------
compnerd wrote:

Does it make sense to consider the C++ STL behaviours? The `All` suffix would generally not be something that the C++ STL would ever use as you are giving an iterator range, so you know that it is everything in that range. That is, `prepend(attributes.begin(), attributes.end())` which is often spelt `insert(0, attributes.begin(), attributes.end())`

https://github.com/llvm/llvm-project/pull/162714


More information about the cfe-commits mailing list