When an impl references an unknown trait, mention what
the trait is called in the error message.
This commit is contained in:
parent
1790400335
commit
31004835e2
1 changed files with 2 additions and 2 deletions
|
|
@ -3831,9 +3831,9 @@ impl Resolver {
|
|||
visitor: ResolveVisitor) {
|
||||
match self.resolve_path(trait_reference.path, TypeNS, true, visitor) {
|
||||
None => {
|
||||
let idents = self.idents_to_str(trait_reference.path.idents);
|
||||
self.session.span_err(trait_reference.path.span,
|
||||
"attempt to implement an \
|
||||
unknown trait");
|
||||
fmt!("attempt to implement an unknown trait `%s`", idents));
|
||||
}
|
||||
Some(def) => {
|
||||
self.record_def(trait_reference.ref_id, def);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue