Add a helper class for implementing intrusive linked lists
Change-Id: I6a5b25be916c6cfeb760fc3ed38637914e8af3a4
diff --git a/aos/common/util/BUILD b/aos/common/util/BUILD
index bd70463..7f045bd 100644
--- a/aos/common/util/BUILD
+++ b/aos/common/util/BUILD
@@ -179,3 +179,25 @@
'compiler_memory_barrier.h',
],
)
+
+cc_library(
+ name = 'linked_list',
+ hdrs = [
+ 'linked_list.h',
+ ],
+ deps = [
+ '//aos/common:transaction',
+ ],
+)
+
+cc_test(
+ name = 'linked_list_test',
+ srcs = [
+ 'linked_list_test.cc',
+ ],
+ deps = [
+ ':linked_list',
+ '//aos/testing:googletest',
+ '//aos/common/logging',
+ ],
+)