diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2015-01-06 15:05:53 -0800 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2015-01-06 15:05:53 -0800 |
| commit | 1afe8a4fb86fe54be8008b033de166d9c1f8f650 (patch) | |
| tree | c7f8c61d1f944c6f2b4a1c59979bfa4b0fae3cfa /src/libsyntax/diagnostics/plugin.rs | |
| parent | ea6f65c5f1a3f84e010d2cef02a0160804e9567a (diff) | |
| parent | 0c7f7a5fb8919c6a382f9acd1e921c51f807f625 (diff) | |
| download | rust-1afe8a4fb86fe54be8008b033de166d9c1f8f650.tar.gz rust-1afe8a4fb86fe54be8008b033de166d9c1f8f650.zip | |
rollup merge of #20562: nick29581/arrays-3
Diffstat (limited to 'src/libsyntax/diagnostics/plugin.rs')
| -rw-r--r-- | src/libsyntax/diagnostics/plugin.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsyntax/diagnostics/plugin.rs b/src/libsyntax/diagnostics/plugin.rs index 720a907fe77..0f4ebd74b66 100644 --- a/src/libsyntax/diagnostics/plugin.rs +++ b/src/libsyntax/diagnostics/plugin.rs @@ -58,7 +58,7 @@ pub fn expand_diagnostic_used<'cx>(ecx: &'cx mut ExtCtxt, Some(previous_span) => { ecx.span_warn(span, format!( "diagnostic code {} already used", token::get_ident(code).get() - )[]); + ).index(&FullRange)); ecx.span_note(previous_span, "previous invocation"); }, None => () @@ -87,12 +87,12 @@ pub fn expand_register_diagnostic<'cx>(ecx: &'cx mut ExtCtxt, if diagnostics.insert(code.name, description).is_some() { ecx.span_err(span, format!( "diagnostic code {} already registered", token::get_ident(*code).get() - )[]); + ).index(&FullRange)); } }); let sym = Ident::new(token::gensym(( "__register_diagnostic_".to_string() + token::get_ident(*code).get() - )[])); + ).index(&FullRange))); MacItems::new(vec![quote_item!(ecx, mod $sym {}).unwrap()].into_iter()) } |
