Skip to content

Commit 34ab7d5

Browse files
committed
update readme and crate version
1 parent 3925ce9 commit 34ab7d5

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "displaydoc"
3-
version = "0.1.4"
3+
version = "0.1.5"
44
authors = ["Jane Lusby <jlusby@yaah.dev>"]
55
edition = "2018"
66
license = "MIT OR Apache-2.0"

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ This library provides a convenient derive macro for the standard library's
1111

1212
```toml
1313
[dependencies]
14-
displaydoc = "0.1.4"
14+
displaydoc = "0.1"
1515
```
1616

1717
*Compiler support: requires rustc 1.31+*
@@ -62,6 +62,9 @@ pub enum DataStoreError {
6262
1. **Is this crate `no_std` compatible?**
6363
* Yes! This crate implements the `core::fmt::Display` trait not the `std::fmt::Display` trait so it should work in `std` and `no_std` environments.
6464

65+
2. **Does this crate work with `Path` and `PathBuf` via the `Display` trait?**
66+
* Yuuup. This crate uses @dtolnay's [autoref specialization technique](https://github.com/dtolnay/case-studies/blob/master/autoref-specialization/README.md) to add a special trait for types to get the display impl, it then specializes for `Path` and `PathBuf` and when either of these types are found it calls `self.display()` to get a `std::path::Display<'_>` type which can be used with the Display format specifier!
67+
6568
<br>
6669

6770
#### License

0 commit comments

Comments
 (0)