Skip to content

Commit

Permalink
Merge pull request #1742 from solson/patch-3
Browse files Browse the repository at this point in the history
Block quote the entire style guideline example.
  • Loading branch information
eddyb authored Sep 6, 2016
2 parents 902e54c + 5962091 commit 9216e4f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions text/1607-style-rfcs.md
Original file line number Diff line number Diff line change
Expand Up @@ -192,15 +192,17 @@ Guidelines may include more than one acceptable rule, but should offer
guidance for when to use each rule (which should be formal enough to be used by
a tool).

For example: "a struct literal must be formatted either on a single line (with
For example:

> A struct literal must be formatted either on a single line (with
spaces after the opening brace and before the closing brace, and with fields
separated by commas and spaces), or on multiple lines (with one field per line
and newlines after the opening brace and before the closing brace). The former
approach should be used for short struct literals, the latter for longer struct
literals. For tools, the first approach should be used when the width of the
fields (excluding commas and braces) is 16 characters. E.g.,

```
> ```rust
let x = Foo { a: 42, b: 34 };
let y = Foo {
a: 42,
Expand Down

0 comments on commit 9216e4f

Please sign in to comment.