Closed Razican closed 7 years ago
Closing with: https://github.com/gnieto/abxml-rs/pull/43
Implementing ToOwned
on buffers means that Borrow
needs to be implemented on wrappers. Implementing Borrow
is supposed to be non-allocating, which is not possible with the current architecture.
The intention is to implement TryFrom
(https://doc.rust-lang.org/core/convert/trait.TryFrom.html) on buffers when it will be stable.
Some Clippy warnings show that the correct way of implementing
to_owned
methods is usingstd::borrow::ToOwned
. I think it's a good idea to implement it that way.