Skip to content

Commit 157ba00

Browse files
committed
Clarify that ParameterEnvironment::for_item can take impl/trait items too
1 parent 68de28b commit 157ba00

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/librustc/ty/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1202,6 +1202,7 @@ impl<'a, 'tcx> ParameterEnvironment<'a, 'tcx> {
12021202
}
12031203
}
12041204

1205+
/// Construct a parameter environment given an item, impl item, or trait item
12051206
pub fn for_item(cx: &'a TyCtxt<'tcx>, id: NodeId) -> ParameterEnvironment<'a, 'tcx> {
12061207
match cx.map.find(id) {
12071208
Some(ast_map::NodeImplItem(ref impl_item)) => {

0 commit comments

Comments
 (0)