diff options
| author | Mazdak Farrokhzad <twingoow@gmail.com> | 2019-06-08 03:33:55 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-06-08 03:33:55 +0200 |
| commit | 5062ad3c60367abb4566885a3276b9305edcf614 (patch) | |
| tree | 241990a5fae0edce0cfaa970e556da9dcd76fa00 /src/test/ui/thinlto | |
| parent | 2a9bcbf9a9e1641288a2024de4843382f4ff4c2d (diff) | |
| parent | 2af47facc3fd7eda3fb4e52f0589bb6f48eff15c (diff) | |
| download | rust-5062ad3c60367abb4566885a3276b9305edcf614.tar.gz rust-5062ad3c60367abb4566885a3276b9305edcf614.zip | |
Rollup merge of #61615 - petrochenkov:errlit, r=matklad
syntax: Treat error literals in more principled way Free them from their character literal origins. I actually tried to remove `LitKind::Err` entirely (by converting it into `ExprKind::Err` immediately), and it caused no diagnostic regressions in the test suite. However, I'd still want to use error literals as general purpose error tokens some day, so I kept them. The downside of having `LitKind::Err` in addition to `ExprKind::Err` is that every time you want to do something with `ExprKind::Err` you need to make sure that `ExprKind::Lit(LitKind::Err)` is treated in the same way. Fortunately, this usually happens automatically because both literals and errors are "leaf" expressions, however this PR does fix a couple of inconsistencies between them. Addresses https://github.com/rust-lang/rust/pull/60679#discussion_r282640663 in a way
Diffstat (limited to 'src/test/ui/thinlto')
0 files changed, 0 insertions, 0 deletions
