diff options
| author | Vadim Petrochenkov <vadim.petrochenkov@gmail.com> | 2019-06-07 12:53:33 +0300 |
|---|---|---|
| committer | Vadim Petrochenkov <vadim.petrochenkov@gmail.com> | 2019-06-07 18:01:50 +0300 |
| commit | 2af47facc3fd7eda3fb4e52f0589bb6f48eff15c (patch) | |
| tree | 46549007a191f5676a28704a3da1cfbd5eacdf7d /src/libsyntax/ast.rs | |
| parent | c1c60d292e2dd2deff7084208274f9a02f750d43 (diff) | |
| download | rust-2af47facc3fd7eda3fb4e52f0589bb6f48eff15c.tar.gz rust-2af47facc3fd7eda3fb4e52f0589bb6f48eff15c.zip | |
syntax: Treat error literals in more principled way
Diffstat (limited to 'src/libsyntax/ast.rs')
| -rw-r--r-- | src/libsyntax/ast.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsyntax/ast.rs b/src/libsyntax/ast.rs index 598232f9f8f..02fbcb14fa5 100644 --- a/src/libsyntax/ast.rs +++ b/src/libsyntax/ast.rs @@ -1368,7 +1368,7 @@ pub enum LitKind { FloatUnsuffixed(Symbol), /// A boolean literal. Bool(bool), - /// A recovered character literal that contains mutliple `char`s, most likely a typo. + /// Placeholder for a literal that wasn't well-formed in some way. Err(Symbol), } @@ -1406,10 +1406,10 @@ impl LitKind { | LitKind::ByteStr(..) | LitKind::Byte(..) | LitKind::Char(..) - | LitKind::Err(..) | LitKind::Int(_, LitIntType::Unsuffixed) | LitKind::FloatUnsuffixed(..) - | LitKind::Bool(..) => true, + | LitKind::Bool(..) + | LitKind::Err(..) => true, // suffixed variants LitKind::Int(_, LitIntType::Signed(..)) | LitKind::Int(_, LitIntType::Unsigned(..)) |
