about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorkennytm <kennytm@gmail.com>2018-01-13 02:26:33 +0800
committerGitHub <noreply@github.com>2018-01-13 02:26:33 +0800
commit9bedbcc9bf62cefdd6d947ecf18eb53f71b28f48 (patch)
tree80209065767eb8a3343f3201ff20eb66f3c26254 /src
parentdf8f2c6eda4515c04f556dd7071481117f428b0b (diff)
parentc78679db08264f1fc9aac3841242648600a0cc6f (diff)
downloadrust-9bedbcc9bf62cefdd6d947ecf18eb53f71b28f48.tar.gz
rust-9bedbcc9bf62cefdd6d947ecf18eb53f71b28f48.zip
Rollup merge of #47307 - dlrobertson:fix_panic_strings, r=kennytm
Fix panic strings.

 - Fix panic string in `check_ast_crate`.
 - Update panic string for Duration subtraction on overflow/underflow.

Not sure if the changes to `Duration` are helpful/needed. Mostly just a nit.
Otherwise this is just a one character change :)

On another note: I hit the panic in `check_ast_crate` when compiling
[m-labs/smoltcp] with the following:

```
cargo test --doc --no-default-features --features "std socket-raw"`
```

[m-labs/smoltcp]: https://github.com/m-labs/smoltcp
Diffstat (limited to 'src')
-rw-r--r--src/librustc/lint/context.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc/lint/context.rs b/src/librustc/lint/context.rs
index 32ab458cb91..5336c1944e8 100644
--- a/src/librustc/lint/context.rs
+++ b/src/librustc/lint/context.rs
@@ -1046,7 +1046,7 @@ pub fn check_ast_crate(sess: &Session, krate: &ast::Crate) {
     // calculated the lint levels for all AST nodes.
     for (_id, lints) in cx.buffered.map {
         for early_lint in lints {
-            span_bug!(early_lint.span, "failed to process bufferd lint here");
+            span_bug!(early_lint.span, "failed to process buffered lint here");
         }
     }
 }