@@ -18,8 +18,11 @@ mod tests;
1818///
1919/// [`iter()`]: #method.iter
2020/// [`for_each_mut()`]: #method.for_each_mut
21+ #[ allow(
22+ clippy:: exhaustive_structs,
23+ reason = "This cannot be extended without breaking preprocessors."
24+ ) ]
2125#[ derive( Debug , Clone , Default , PartialEq , Serialize , Deserialize ) ]
22- #[ non_exhaustive]
2326pub struct Book {
2427 /// The items in this book.
2528 pub items : Vec < BookItem > ,
8083}
8184
8285/// Enum representing any type of item which can be added to a book.
86+ #[ allow(
87+ clippy:: exhaustive_enums,
88+ reason = "This cannot be extended without breaking preprocessors."
89+ ) ]
8390#[ derive( Debug , Clone , PartialEq , Serialize , Deserialize ) ]
84- #[ non_exhaustive]
8591pub enum BookItem {
8692 /// A nested chapter.
8793 Chapter ( Chapter ) ,
@@ -99,8 +105,11 @@ impl From<Chapter> for BookItem {
99105
100106/// The representation of a "chapter", usually mapping to a single file on
101107/// disk however it may contain multiple sub-chapters.
108+ #[ allow(
109+ clippy:: exhaustive_structs,
110+ reason = "This cannot be extended without breaking preprocessors."
111+ ) ]
102112#[ derive( Debug , Clone , Default , PartialEq , Serialize , Deserialize ) ]
103- #[ non_exhaustive]
104113pub struct Chapter {
105114 /// The chapter's name.
106115 pub name : String ,
0 commit comments