On Fri Sep 29, 2023 at 12:39 PM CEST, Viresh Kumar wrote: > On 28-09-23, 15:24, Erik Schilling wrote: > > > +/// Line info > > > +/// > > > +/// This is the owned counterpart to [Info]. Due to a [Deref] implementation, > > > +/// all functions of [Info] can also be called on this type. > > > +#[derive(Debug)] > > > +pub struct InfoOwned { > > > + info: *mut gpiod::gpiod_line_info, > > > +} > > > > While going through all the structs in order to add missing `Send` > > implementations, it occured to me that it may be a bit confusing if > > only this one type has the `Owned` suffix, while the others are also > > "owned" but do not carry that suffix. > > > > Not really sure how to resolve this... We could rename the non-owned > > `Info` to something like `InfoRef` and turn `InfoOwned` back into > > `Info`, but reading `&InfoRef` may be a bit weird? > > I like this one and none of the others. OK :). With Manos also agreeing, I will do this then. > > > Alternatively, we could rename all other structs to add the suffix... > > Then, "Owned" would maybe sound confusing - given that no un-owned > > variant exists. > > Maybe "Box" would be a more suitable suffix in that case - borrowing > > from the Box type name [1]? > > > > Any opinions here? > > > > [1] https://doc.rust-lang.org/std/boxed/struct.Box.html