Fix dyn objects
This commit is contained in:
parent
e0f8f871f6
commit
2758de4b95
1 changed files with 2 additions and 2 deletions
|
@ -16,7 +16,7 @@ pub fn get_def_ctor_from_def_id<F>(cx: &DocContext,
|
|||
def_id: DefId,
|
||||
callback: &F,
|
||||
) -> Vec<Item>
|
||||
where F: Fn(&Fn(DefId) -> Def) -> Vec<Item> {
|
||||
where F: Fn(& dyn Fn(DefId) -> Def) -> Vec<Item> {
|
||||
let ty = cx.tcx.type_of(def_id);
|
||||
|
||||
match ty.sty {
|
||||
|
@ -53,7 +53,7 @@ pub fn get_def_ctor_from_node_id<F>(cx: &DocContext,
|
|||
name: String,
|
||||
callback: &F,
|
||||
) -> Vec<Item>
|
||||
where F: Fn(&Fn(DefId) -> Def, String) -> Vec<Item> {
|
||||
where F: Fn(& dyn Fn(DefId) -> Def, String) -> Vec<Item> {
|
||||
let item = &cx.tcx.hir.expect_item(id).node;
|
||||
|
||||
callback(&match *item {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue