Formatting

This commit is contained in:
Edwin Cheng 2019-12-24 19:52:48 +08:00
parent 0edb5b4a50
commit d0537cda9e
2 changed files with 4 additions and 3 deletions

View file

@ -80,9 +80,7 @@ impl FunctionData {
fn desugar_future_path(orig: TypeRef) -> Path {
let path = path![std::future::Future];
let mut generic_args: Vec<_> = std::iter::repeat(None).take(path.segments.len() - 1).collect();
let mut last = GenericArgs::empty();
last.bindings.push((name![Output], orig));
generic_args.push(Some(Arc::new(last)));

View file

@ -131,7 +131,10 @@ impl Path {
}
/// Converts a known mod path to `Path`.
pub(crate) fn from_known_path(path: ModPath, generic_args: Vec<Option<Arc<GenericArgs>>>) -> Path {
pub(crate) fn from_known_path(
path: ModPath,
generic_args: Vec<Option<Arc<GenericArgs>>>,
) -> Path {
Path { type_anchor: None, mod_path: path, generic_args }
}