Skip to content

Commit

Permalink
Improve spacing around long arrows in documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed Oct 13, 2019
1 parent ee864e1 commit bfe7b5a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions README.md
Expand Up @@ -58,10 +58,10 @@ pub enum DataStoreError {

The messages support a shorthand for interpolating fields from the error.

- `#[error("{var}")]``write!("{}", self.var)`
- `#[error("{0}")]``write!("{}", self.0)`
- `#[error("{var:?}")]``write!("{:?}", self.var)`
- `#[error("{0:?}")]``write!("{:?}", self.0)`
- `#[error("{var}")]`  `write!("{}", self.var)`
- `#[error("{0}")]`  `write!("{}", self.0)`
- `#[error("{var:?}")]`  `write!("{:?}", self.var)`
- `#[error("{0:?}")]`  `write!("{:?}", self.0)`

You may alternatively write out the full format args yourself, using arbitrary
expressions.
Expand Down
8 changes: 4 additions & 4 deletions src/lib.rs
Expand Up @@ -45,10 +45,10 @@
//!
//! The messages support a shorthand for interpolating fields from the error.
//!
//! - `#[error("{var}")]``write!("{}", self.var)`
//! - `#[error("{0}")]``write!("{}", self.0)`
//! - `#[error("{var:?}")]``write!("{:?}", self.var)`
//! - `#[error("{0:?}")]``write!("{:?}", self.0)`
//! - `#[error("{var}")]` ⟶ `write!("{}", self.var)`
//! - `#[error("{0}")]` ⟶ `write!("{}", self.0)`
//! - `#[error("{var:?}")]` ⟶ `write!("{:?}", self.var)`
//! - `#[error("{0:?}")]` ⟶ `write!("{:?}", self.0)`
//!
//! You may alternatively write out the full format args yourself, using
//! arbitrary expressions.
Expand Down

0 comments on commit bfe7b5a

Please sign in to comment.