Skip to content

Commit a745cc5

Browse files
committed
make non_ascii_literal to catch char
1 parent 140ba61 commit a745cc5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clippy_lints/src/unicode.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ declare_lint_pass!(Unicode => [INVISIBLE_CHARACTERS, NON_ASCII_LITERAL, UNICODE_
7575
impl LateLintPass<'_> for Unicode {
7676
fn check_expr(&mut self, cx: &LateContext<'_>, expr: &'_ Expr<'_>) {
7777
if let ExprKind::Lit(ref lit) = expr.kind {
78-
if let LitKind::Str(_, _) = lit.node {
78+
if let LitKind::Str(_, _) | LitKind::Char(_)= lit.node {
7979
check_str(cx, lit.span, expr.hir_id);
8080
}
8181
}

0 commit comments

Comments
 (0)