implement new effects desugaring
This commit is contained in:
parent
99f77a2eda
commit
72e8244e64
50 changed files with 636 additions and 228 deletions
|
@ -585,6 +585,7 @@ impl<'a> State<'a> {
|
|||
self.print_struct(struct_def, generics, item.ident.name, item.span, true);
|
||||
}
|
||||
hir::ItemKind::Impl(&hir::Impl {
|
||||
constness,
|
||||
safety,
|
||||
polarity,
|
||||
defaultness,
|
||||
|
@ -599,6 +600,10 @@ impl<'a> State<'a> {
|
|||
self.print_safety(safety);
|
||||
self.word_nbsp("impl");
|
||||
|
||||
if let hir::Constness::Const = constness {
|
||||
self.word_nbsp("const");
|
||||
}
|
||||
|
||||
if !generics.params.is_empty() {
|
||||
self.print_generic_params(generics.params);
|
||||
self.space();
|
||||
|
@ -2144,7 +2149,7 @@ impl<'a> State<'a> {
|
|||
self.print_type(default);
|
||||
}
|
||||
}
|
||||
GenericParamKind::Const { ty, ref default, is_host_effect: _ } => {
|
||||
GenericParamKind::Const { ty, ref default, is_host_effect: _, synthetic: _ } => {
|
||||
self.word_space(":");
|
||||
self.print_type(ty);
|
||||
if let Some(default) = default {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue