Skip to content
This repository was archived by the owner on Aug 16, 2021. It is now read-only.

Commit 043cca5

Browse files
committed
Misc fixes in the doc.
1 parent 4dd7f02 commit 043cca5

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

src/error_chain.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,9 @@ macro_rules! error_chain {
2727
/// that is mostly irrelevant for error handling purposes.
2828
#[derive(Debug)]
2929
pub struct $error_name {
30+
/// The kind of the error.
3031
pub kind: $error_kind_name,
32+
/// Contains the error chain and the backtrace.
3133
pub state: $crate::State,
3234
}
3335

@@ -192,10 +194,7 @@ macro_rules! error_chain {
192194
}
193195
}
194196

195-
// The Result type
196-
// ---------------
197-
198-
/// Convenient wrapper around std::Result.
197+
/// Convenient wrapper around `std::Result`.
199198
pub type $result_name<T> = ::std::result::Result<T, $error_name>;
200199
};
201200

src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
//! optional, boxed `std::error::Error + Send + 'static` object
3232
//! (which defines the `cause`, and establishes the links in the
3333
//! error chain), and a `Backtrace`.
34-
//! * This crate additionally defines the trait ResultExt
34+
//! * This crate additionally defines the trait `ResultExt`
3535
//! that defines a `chain_err` method. This method
3636
//! on all `std::error::Error + Send + 'static` types extends
3737
//! the error chain by boxing the current error into an opaque
@@ -213,7 +213,7 @@
213213
//!
214214
//! Both types come with a variety of `From` conversions as well:
215215
//! `Error` can be created from `ErrorKind`, `&str` and `String`,
216-
//! and the "link" and "foreign_link" error types. `ErrorKind`
216+
//! and the `links` and `foreign_links` error types. `ErrorKind`
217217
//! can be created from the corresponding `ErrorKind`s of the link
218218
//! types, as well as from `&str` and `String`.
219219
//!

test-doc/src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ extern crate error_chain;
44
/// This module is used to check that all generated items are documented.
55
#[deny(missing_docs)]
66
pub mod doc {
7+
/// Inner module.
78
pub mod inner {
89
error_chain! {
910
}

0 commit comments

Comments
 (0)