Skip to content

Commit 0ee059d

Browse files
committed
Fix rebase fallout and address some review comments.
1 parent 4653ae1 commit 0ee059d

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

src/librustc/ty/print/mod.rs

+8
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@ pub trait Print<'gcx, 'tcx, P> {
1616
fn print(&self, cx: P) -> Result<Self::Output, Self::Error>;
1717
}
1818

19+
/// Interface for outputting user-facing "type-system entities"
20+
/// (paths, types, lifetimes, constants, etc.) as a side-effect
21+
/// (e.g. formatting, like `PrettyPrinter` implementors do) or by
22+
/// constructing some alternative representation (e.g. an AST),
23+
/// which the associated types allow passing through the methods.
24+
///
25+
/// For pretty-printing/formatting in particular, see `PrettyPrinter`.
26+
// FIXME(eddyb) find a better name, this is more general than "printing".
1927
pub trait Printer<'gcx: 'tcx, 'tcx>: Sized {
2028
type Error;
2129

src/librustc/ty/structural_impls.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ impl fmt::Debug for ty::FloatVarValue {
225225

226226
impl fmt::Debug for ty::TraitRef<'tcx> {
227227
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
228-
// HACK(eddyb) this is used across the compiler to print
228+
// FIXME(#59188) this is used across the compiler to print
229229
// a `TraitRef` qualified (with the Self type explicit),
230230
// instead of having a different way to make that choice.
231231
write!(f, "<{} as {}>", self.self_ty(), self)

0 commit comments

Comments
 (0)