I’ve got my hands on a
rustc::middle::ty::FieldDefData struct, while hacking around inside a custom lint pass, and I’d like to ideally get the corresponding
Span for that so I can display helpful error messages.
I have searched the API documentation of all the Rust compiler crates (thanks to http://manishearth.github.io/rust-internals-docs) to try and find something but I haven’t found anything.
I suspect a
Span should be able to be retrieved from a
DefId, as it identifies a particular definition. I just can’t find the function to do it.