mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-28 09:44:08 +00:00
Run x.py fmt
This commit is contained in:
parent
070bf94a6f
commit
a5b3dfe453
@ -775,7 +775,9 @@ pub struct RenderAllocation<'a, 'tcx, Tag, Extra> {
|
||||
alloc: &'a Allocation<Tag, Extra>,
|
||||
}
|
||||
|
||||
impl<'a, 'tcx, Tag: Provenance, Extra> std::fmt::Display for RenderAllocation<'a, 'tcx, Tag, Extra> {
|
||||
impl<'a, 'tcx, Tag: Provenance, Extra> std::fmt::Display
|
||||
for RenderAllocation<'a, 'tcx, Tag, Extra>
|
||||
{
|
||||
fn fmt(&self, w: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
let RenderAllocation { tcx, alloc } = *self;
|
||||
write!(w, "size: {}, align: {})", alloc.size().bytes(), alloc.align.bytes())?;
|
||||
|
@ -76,7 +76,11 @@ pub trait RefDecodable<'tcx, D: TyDecoder<'tcx>> {
|
||||
}
|
||||
|
||||
/// Encode the given value or a previously cached shorthand.
|
||||
pub fn encode_with_shorthand<'tcx, E, T, M>(encoder: &mut E, value: &T, cache: M) -> Result<(), E::Error>
|
||||
pub fn encode_with_shorthand<'tcx, E, T, M>(
|
||||
encoder: &mut E,
|
||||
value: &T,
|
||||
cache: M,
|
||||
) -> Result<(), E::Error>
|
||||
where
|
||||
E: TyEncoder<'tcx>,
|
||||
M: for<'b> Fn(&'b mut E) -> &'b mut FxHashMap<T, usize>,
|
||||
|
Loading…
Reference in New Issue
Block a user