Fix `--allowlist-item`
diff --git a/bindgen/ir/context.rs b/bindgen/ir/context.rs
index c4465df..2e608b0 100644
--- a/bindgen/ir/context.rs
+++ b/bindgen/ir/context.rs
@@ -2530,7 +2530,11 @@
                                 );
                                 let name = prefix_path[1..].join("::");
                                 prefix_path.pop().unwrap();
-                                self.options().allowlisted_vars.matches(name)
+                                self.options().allowlisted_vars.matches(&name)
+                                    || self
+                                        .options()
+                                        .allowlisted_items
+                                        .matches(name)
                             })
                         }
                     }