mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-04 12:44:40 +00:00
parent
2c7e737a06
commit
d48cbedfe4
@ -211,7 +211,7 @@ impl Hash for Target {
|
||||
pub enum CargoFmtStrategy {
|
||||
/// Format every packages and dependencies.
|
||||
All,
|
||||
/// Format pacakges that are specified by the command line argument.
|
||||
/// Format packages that are specified by the command line argument.
|
||||
Some(Vec<String>),
|
||||
/// Format the root packages only.
|
||||
Root,
|
||||
|
@ -279,7 +279,7 @@ impl<'a, T: 'a + Rewrite + ToExpr + Spanned> Context<'a, T> {
|
||||
if self.items.len() == 1 =>
|
||||
{
|
||||
// When we are rewriting a nested function call, we restrict the
|
||||
// bugdet for the inner function to avoid them being deeply nested.
|
||||
// budget for the inner function to avoid them being deeply nested.
|
||||
// However, when the inner function has a prefix or a suffix
|
||||
// (e.g. `foo() as u32`), this budget reduction may produce poorly
|
||||
// formatted code, where a prefix or a suffix being left on its own
|
||||
|
@ -12,7 +12,7 @@
|
||||
//!
|
||||
//! `mod`, `extern crate` and `use` declarations are reorderd in alphabetical
|
||||
//! order. Trait items are reordered in pre-determined order (associated types
|
||||
//! and constatns comes before methods).
|
||||
//! and constants comes before methods).
|
||||
|
||||
// TODO(#2455): Reorder trait items.
|
||||
|
||||
|
@ -732,7 +732,7 @@ fn rewrite_bare_fn(
|
||||
{
|
||||
result.push_str("for<");
|
||||
// 6 = "for<> ".len(), 4 = "for<".
|
||||
// This doesn't work out so nicely for mutliline situation with lots of
|
||||
// This doesn't work out so nicely for multiline situation with lots of
|
||||
// rightward drift. If that is a problem, we could use the list stuff.
|
||||
result.push_str(lifetime_str);
|
||||
result.push_str("> ");
|
||||
|
Loading…
Reference in New Issue
Block a user