Add test
diff --git a/bindgen-tests/tests/expectations/tests/anon_enum_allowlist_item.rs b/bindgen-tests/tests/expectations/tests/anon_enum_allowlist_item.rs
new file mode 100644
index 0000000..4d28c3a
--- /dev/null
+++ b/bindgen-tests/tests/expectations/tests/anon_enum_allowlist_item.rs
@@ -0,0 +1,4 @@
+#![allow(dead_code, non_snake_case, non_camel_case_types, non_upper_case_globals)]
+pub const NODE_FLAG_FOO: _bindgen_ty_1 = 0;
+pub const NODE_FLAG_BAR: _bindgen_ty_1 = 1;
+pub type _bindgen_ty_1 = ::std::os::raw::c_uint;
diff --git a/bindgen-tests/tests/headers/anon_enum_allowlist_item.h b/bindgen-tests/tests/headers/anon_enum_allowlist_item.h
new file mode 100644
index 0000000..23caacc
--- /dev/null
+++ b/bindgen-tests/tests/headers/anon_enum_allowlist_item.h
@@ -0,0 +1,6 @@
+// bindgen-flags: --allowlist-item "NODE_.*"
+
+enum {
+  NODE_FLAG_FOO,
+  NODE_FLAG_BAR,
+};