Skip to content

Commit

Permalink
Auto merge of #38047 - canndrew:fmt-void-non-empty, r=bluss
Browse files Browse the repository at this point in the history
Make core::fmt::Void a non-empty type.

Adding back this change that was removed from PR #36449 because it's a fix and because I immediately hit a problem with it again when I started implementing my fix for #12609.
  • Loading branch information
bors committed Nov 30, 2016
2 parents ecff71a + 246edb8 commit dc81742
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/libcore/fmt/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,9 @@ pub struct Formatter<'a> {
// NB. Argument is essentially an optimized partially applied formatting function,
// equivalent to `exists T.(&T, fn(&T, &mut Formatter) -> Result`.

enum Void {}
struct Void {
_priv: (),
}

/// This struct represents the generic "argument" which is taken by the Xprintf
/// family of functions. It contains a function to format the given value. At
Expand Down

0 comments on commit dc81742

Please sign in to comment.