about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2015-05-28 13:57:36 +0000
committerbors <bors@rust-lang.org>2015-05-28 13:57:36 +0000
commita5a5fcee386119b016c4ef8908cbd449dc65b730 (patch)
tree939a86c26707c23602337b517c782d492decc3ea
parent4233cbda8aa917090ee7c3a50a842abb34563c6f (diff)
parent62e5dee1c5743bb01b32a8b7eec691c02d528bf3 (diff)
downloadrust-a5a5fcee386119b016c4ef8908cbd449dc65b730.tar.gz
rust-a5a5fcee386119b016c4ef8908cbd449dc65b730.zip
Auto merge of #25834 - steveklabnik:gh25326, r=alexcrichton
Fixes #25326
-rw-r--r--src/librustc/diagnostics.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/librustc/diagnostics.rs b/src/librustc/diagnostics.rs
index d1e7084150e..a1fa1834ef4 100644
--- a/src/librustc/diagnostics.rs
+++ b/src/librustc/diagnostics.rs
@@ -218,9 +218,9 @@ Therefore, casting one of these non-constant pointers to an integer results
 in a non-constant integer which lead to this error. Example:
 
 ```
-const X: u32 = 50;
-const Y: *const u32 = &X;
-println!("{:?}", Y);
+const X: u32 = 1;
+const Y: usize = &X as *const u32 as usize;
+println!("{}", Y);
 ```
 "##,