Skip to content

Commit

Permalink
Put #[inline] in the correct place
Browse files Browse the repository at this point in the history
At present, the macro only adds `#[inline]` to the first method.
  • Loading branch information
ecstatic-morse committed Apr 16, 2020
1 parent 93e0d47 commit 99cca04
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/librustc_middle/ty/query/on_disk_cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -909,10 +909,12 @@ where

macro_rules! encoder_methods {
($($name:ident($ty:ty);)*) => {
#[inline]
$(fn $name(&mut self, value: $ty) -> Result<(), Self::Error> {
self.encoder.$name(value)
})*
$(
#[inline]
fn $name(&mut self, value: $ty) -> Result<(), Self::Error> {
self.encoder.$name(value)
}
)*
}
}

Expand Down

0 comments on commit 99cca04

Please sign in to comment.