Skip to content

Commit

Permalink
Auto merge of rust-lang#94928 - lcnr:inline-as_substs, r=michaelwoeri…
Browse files Browse the repository at this point in the history
…ster

inline `tuple_fields`

more rust-lang#93505 fun, after this i have no idea what might be causing the perf impact.
  • Loading branch information
bors committed Mar 15, 2022
2 parents 0407030 + 423600d commit be52b4a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions compiler/rustc_middle/src/ty/sty.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2162,6 +2162,7 @@ impl<'tcx> Ty<'tcx> {

/// Iterates over tuple fields.
/// Panics when called on anything but a tuple.
#[inline]
pub fn tuple_fields(self) -> &'tcx List<Ty<'tcx>> {
match self.kind() {
Tuple(substs) => substs,
Expand Down

0 comments on commit be52b4a

Please sign in to comment.