File tree 3 files changed +10
-5
lines changed
3 files changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -1056,8 +1056,9 @@ impl<'a> LocalCrateReader<'a> {
1056
1056
Some ( "dylib" ) => cstore:: NativeUnknown ,
1057
1057
Some ( "framework" ) => cstore:: NativeFramework ,
1058
1058
Some ( k) => {
1059
- span_err ! ( self . sess, m. span, E0458 ,
1060
- "unknown kind: `{}`" , k) ;
1059
+ struct_span_err ! ( self . sess, m. span, E0458 ,
1060
+ "unknown kind: `{}`" , k)
1061
+ . span_label ( m. span , & format ! ( "unknown kind" ) ) . emit ( ) ;
1061
1062
cstore:: NativeUnknown
1062
1063
}
1063
1064
None => cstore:: NativeUnknown
@@ -1068,8 +1069,9 @@ impl<'a> LocalCrateReader<'a> {
1068
1069
let n = match n {
1069
1070
Some ( n) => n,
1070
1071
None => {
1071
- span_err ! ( self . sess, m. span, E0459 ,
1072
- "#[link(...)] specified without `name = \" foo\" `" ) ;
1072
+ struct_span_err ! ( self . sess, m. span, E0459 ,
1073
+ "#[link(...)] specified without `name = \" foo\" `" )
1074
+ . span_label ( m. span , & format ! ( "missing `name` argument" ) ) . emit ( ) ;
1073
1075
InternedString :: new ( "foo" )
1074
1076
}
1075
1077
} ;
Original file line number Diff line number Diff line change 9
9
// except according to those terms.
10
10
11
11
#[ link( kind = "wonderful_unicorn" ) ] extern { } //~ ERROR E0458
12
- //~^ ERROR E0459
12
+ //~| NOTE unknown kind
13
+ //~| ERROR E0459
14
+ //~| NOTE missing `name` argument
13
15
14
16
fn main ( ) {
15
17
}
Original file line number Diff line number Diff line change 9
9
// except according to those terms.
10
10
11
11
#[ link( kind = "dylib" ) ] extern { } //~ ERROR E0459
12
+ //~| NOTE missing `name` argument
12
13
13
14
fn main ( ) {
14
15
}
You can’t perform that action at this time.
0 commit comments