Add missing '?' to format grammar.

This commit is contained in:
Alexis Hunt 2018-03-26 21:18:50 -04:00
parent 5570cdcc9e
commit 554dd3e350
1 changed files with 8 additions and 7 deletions

View File

@ -324,7 +324,7 @@
//! sign := '+' | '-'
//! width := count
//! precision := count | '*'
//! type := identifier | ''
//! type := identifier | '?' | ''
//! count := parameter | integer
//! parameter := argument '$'
//! ```
@ -514,17 +514,17 @@ pub use core::fmt::rt;
#[stable(feature = "rust1", since = "1.0.0")]
pub use core::fmt::{Formatter, Result, Write};
#[stable(feature = "rust1", since = "1.0.0")]
pub use core::fmt::{Octal, Binary};
pub use core::fmt::{Binary, Octal};
#[stable(feature = "rust1", since = "1.0.0")]
pub use core::fmt::{Display, Debug};
pub use core::fmt::{Debug, Display};
#[stable(feature = "rust1", since = "1.0.0")]
pub use core::fmt::{LowerHex, UpperHex, Pointer};
pub use core::fmt::{LowerHex, Pointer, UpperHex};
#[stable(feature = "rust1", since = "1.0.0")]
pub use core::fmt::{LowerExp, UpperExp};
#[stable(feature = "rust1", since = "1.0.0")]
pub use core::fmt::Error;
#[stable(feature = "rust1", since = "1.0.0")]
pub use core::fmt::{ArgumentV1, Arguments, write};
pub use core::fmt::{write, ArgumentV1, Arguments};
#[stable(feature = "rust1", since = "1.0.0")]
pub use core::fmt::{DebugList, DebugMap, DebugSet, DebugStruct, DebugTuple};
@ -561,7 +561,8 @@ use string;
pub fn format(args: Arguments) -> string::String {
let capacity = args.estimated_capacity();
let mut output = string::String::with_capacity(capacity);
output.write_fmt(args)
.expect("a formatting trait implementation returned an error");
output
.write_fmt(args)
.expect("a formatting trait implementation returned an error");
output
}