From: Bruno Haible Date: Sun, 3 May 2026 12:07:23 +0000 (+0200) Subject: avltreehash-list: Use the counted_by attribute. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3df9402a0dd2feb03fc06fa343daadc09fdbb60b;p=thirdparty%2Fgnulib.git avltreehash-list: Use the counted_by attribute. * lib/gl_anyavltree_list1.h (struct gl_list_impl): Mark the table field as counted_by table_size. Swap these fields (needed for clang). --- diff --git a/ChangeLog b/ChangeLog index 08307dec69..84b05af28e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2026-05-03 Bruno Haible + + avltreehash-list: Use the counted_by attribute. + * lib/gl_anyavltree_list1.h (struct gl_list_impl): Mark the table field + as counted_by table_size. Swap these fields (needed for clang). + 2026-05-03 Bruno Haible carray-list: Use the counted_by attribute. diff --git a/lib/gl_anyavltree_list1.h b/lib/gl_anyavltree_list1.h index 7c430fa077..760d56d61b 100644 --- a/lib/gl_anyavltree_list1.h +++ b/lib/gl_anyavltree_list1.h @@ -56,8 +56,9 @@ struct gl_list_impl struct gl_list_impl_base base; #if WITH_HASHTABLE /* A hash table: managed as an array of collision lists. */ - struct gl_hash_entry **table; size_t table_size; + struct gl_hash_entry **table + _GL_ATTRIBUTE_COUNTED_BY (table_size); #endif struct gl_list_node_impl *root; /* root node or NULL */ };