commit | 353e8a11396f178557cd0dd856a9e564260cab5d | [log] [tgz] |
---|---|---|
author | Android Build Coastguard Worker <[email protected]> | Fri Mar 10 02:19:23 2023 +0000 |
committer | Android Build Coastguard Worker <[email protected]> | Fri Mar 10 02:19:23 2023 +0000 |
tree | 567bc5f6ef4c9372696cd6f45006bd082d225f96 | |
parent | 6ae78cb6d214003f8c901c22ea6bbc973d291b44 [diff] | |
parent | 0c012951ef4fdc5a647781d457263381820cb224 [diff] |
Snap for 9719949 from 0c012951ef4fdc5a647781d457263381820cb224 to udc-release Change-Id: I9403b2ec1f6a1884edd86648e8c5c6b7c175299d
Simple, Low-level I/O traits
This crate provides two simple traits: Read
and Write
. These traits mimic their counterparts in std::io
, but are trimmed for simplicity and can be used in no_std
and no_alloc
environments. Since this crate contains only traits, inline functions and unit structs, it should be a zero-cost abstraction.
If the std
feature is enabled, we provide blanket implementations for all std::io
types. If the alloc
feature is enabled, we provide implementations for Vec<u8>
. In all cases, you get implementations for byte slices. You can, of course, implement the traits for your own types.
License: Apache-2.0