Apply track_caller to closure on expect_non_local()
This commit is contained in:
parent
16a0d03698
commit
c7db4b08ff
@ -671,7 +671,10 @@ impl<Id> Res<Id> {
|
||||
|
||||
#[track_caller]
|
||||
pub fn expect_non_local<OtherId>(self) -> Res<OtherId> {
|
||||
self.map_id(|_| panic!("unexpected `Res::Local`"))
|
||||
self.map_id(
|
||||
#[track_caller]
|
||||
|_| panic!("unexpected `Res::Local`"),
|
||||
)
|
||||
}
|
||||
|
||||
pub fn macro_kind(self) -> Option<MacroKind> {
|
||||
|
@ -3,6 +3,7 @@
|
||||
//! [rustc dev guide]: https://rustc-dev-guide.rust-lang.org/hir.html
|
||||
|
||||
#![feature(associated_type_defaults)]
|
||||
#![feature(closure_track_caller)]
|
||||
#![feature(const_btree_new)]
|
||||
#![feature(let_else)]
|
||||
#![feature(once_cell)]
|
||||
|
Loading…
x
Reference in New Issue
Block a user