Skip to content

Commit

Permalink
Drop support for compilers older than 1.45
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed Apr 11, 2024
1 parent 22d017e commit 83a5422
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
4 changes: 0 additions & 4 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ fn main() {
None => return,
};

if compiler < 45 {
println!("cargo:rustc-cfg=no_span_mixed_site");
}

if compiler < 47 {
println!("cargo:rustc-cfg=self_span_hack");
}
Expand Down
4 changes: 1 addition & 3 deletions src/expand.rs
Original file line number Diff line number Diff line change
Expand Up @@ -427,9 +427,7 @@ fn transform_block(context: Context, sig: &mut Signature, block: &mut Block) {
}

fn positional_arg(i: usize, pat: &Pat) -> Ident {
let span: Span = syn::spanned::Spanned::span(pat);
#[cfg(not(no_span_mixed_site))]
let span = span.resolved_at(Span::mixed_site());
let span = syn::spanned::Spanned::span(pat).resolved_at(Span::mixed_site());
format_ident!("__arg{}", i, span = span)
}

Expand Down

0 comments on commit 83a5422

Please sign in to comment.