about summary refs log tree commit diff
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2022-04-26 15:21:15 +1000
committerNicholas Nethercote <n.nethercote@gmail.com>2022-04-27 08:15:12 +1000
commite08df2dd6b7c0470796ef8801635e60b8a21d34e (patch)
tree108af92ee9eb2af7773baa32b09a92385894c05d
parent10954cfd4c2a6a847d522540c81f654219bb9ce5 (diff)
downloadrust-e08df2dd6b7c0470796ef8801635e60b8a21d34e.tar.gz
rust-e08df2dd6b7c0470796ef8801635e60b8a21d34e.zip
Avoid producing `NoDelim` values in `MacArgs::delim()`.
-rw-r--r--src/expr.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/expr.rs b/src/expr.rs
index 4f333cd27ce..cd724373f4d 100644
--- a/src/expr.rs
+++ b/src/expr.rs
@@ -1325,7 +1325,7 @@ pub(crate) fn can_be_overflowed_expr(
         }
         ast::ExprKind::MacCall(ref mac) => {
             match (
-                rustc_ast::ast::MacDelimiter::from_token(mac.args.delim()),
+                rustc_ast::ast::MacDelimiter::from_token(mac.args.delim().unwrap()),
                 context.config.overflow_delimited_expr(),
             ) {
                 (Some(ast::MacDelimiter::Bracket), true)