diff options
| author | kennytm <kennytm@gmail.com> | 2017-11-22 01:12:59 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-11-22 01:12:59 +0800 |
| commit | 0af67a4df0219d518ecba6711ff8ff6680a9a2ec (patch) | |
| tree | 850fd666fcd77c62c2cdf792282e7bd106ef8ebc /src/librustc_errors | |
| parent | 9b090a026108fab89cfe5f39bfd3492597e76ad4 (diff) | |
| parent | e7b2702172b91624406e8c90716a225e8ec1a299 (diff) | |
| download | rust-0af67a4df0219d518ecba6711ff8ff6680a9a2ec.tar.gz rust-0af67a4df0219d518ecba6711ff8ff6680a9a2ec.zip | |
Rollup merge of #46052 - oli-obk:rendered_diagnostics_in_json, r=petrochenkov
Include rendered diagnostic in json r? @petrochenkov
Diffstat (limited to 'src/librustc_errors')
| -rw-r--r-- | src/librustc_errors/snippet.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_errors/snippet.rs b/src/librustc_errors/snippet.rs index b76036b22df..c2f4701999e 100644 --- a/src/librustc_errors/snippet.rs +++ b/src/librustc_errors/snippet.rs @@ -70,7 +70,7 @@ impl MultilineAnnotation { pub fn as_end(&self) -> Annotation { Annotation { - start_col: self.end_col - 1, + start_col: self.end_col.saturating_sub(1), end_col: self.end_col, is_primary: self.is_primary, label: self.label.clone(), |
