Refactor: Convert TypeAnnotation::TagUnion to to_node (already working)

This commit is contained in:
Joshua Warner 2024-12-21 19:01:13 -05:00
parent 95d8fd471b
commit 9ae5dc1bbc
No known key found for this signature in database
GPG key ID: 89AD497003F93FDD

View file

@ -303,23 +303,8 @@ fn fmt_ty_ann(
buf.push('_')
}
TypeAnnotation::TagUnion { tags, ext } => {
fmt_tag_collection(buf, indent, *tags, newlines);
fmt_ext(ext, buf, indent);
}
// TypeAnnotation::Tuple { elems: fields, ext } => {
// fmt_ty_collection(buf, indent, Braces::Round, *fields, newlines);
// fmt_ext(ext, buf, indent);
// }
// TypeAnnotation::Record { fields, ext } => {
// fmt_ty_field_collection(buf, indent, *fields, newlines);
// fmt_ext(ext, buf, indent);
// }
// TypeAnnotation::TagUnion { .. } |
TypeAnnotation::Tuple { .. }
TypeAnnotation::TagUnion { .. }
| TypeAnnotation::Tuple { .. }
| TypeAnnotation::Record { .. }
| TypeAnnotation::Function(..)
| TypeAnnotation::As(..) => {