diff --git a/pyo3-macros-backend/src/pyclass.rs b/pyo3-macros-backend/src/pyclass.rs index f10ba20c..74f8b945 100644 --- a/pyo3-macros-backend/src/pyclass.rs +++ b/pyo3-macros-backend/src/pyclass.rs @@ -1010,7 +1010,7 @@ fn define_inventory_class(inventory_class_name: &syn::Ident) -> TokenStream { items: _pyo3::impl_::pyclass::PyClassItems, } impl #inventory_class_name { - const fn new(items: _pyo3::impl_::pyclass::PyClassItems) -> Self { + pub const fn new(items: _pyo3::impl_::pyclass::PyClassItems) -> Self { Self { items } } }