From ae9c09d3602fff3c98dbb4488147059f1024ff69 Mon Sep 17 00:00:00 2001 From: hank-der-hafenarbeiter Date: Tue, 9 Aug 2016 01:39:23 +0200 Subject: [PATCH] Updated error for E0045 (no bonus) --- src/librustc_typeck/lib.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/librustc_typeck/lib.rs b/src/librustc_typeck/lib.rs index 65e00705121a..37de3b1f6096 100644 --- a/src/librustc_typeck/lib.rs +++ b/src/librustc_typeck/lib.rs @@ -181,8 +181,10 @@ fn require_c_abi_if_variadic(tcx: TyCtxt, abi: Abi, span: Span) { if decl.variadic && abi != Abi::C { - span_err!(tcx.sess, span, E0045, + let mut err = struct_span_err!(tcx.sess, span, E0045, "variadic function must have C calling convention"); + err.span_label(span, &("variadics require C calling conventions").to_string()) + .emit(); } }