From 654c836f66819403418285c2556d341e93396ce7 Mon Sep 17 00:00:00 2001 From: Jia-Xuan Liu Date: Wed, 22 May 2024 20:36:14 +0800 Subject: [PATCH] fix the parameter name --- datafusion/sql/src/unparser/dialect.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/datafusion/sql/src/unparser/dialect.rs b/datafusion/sql/src/unparser/dialect.rs index 0cec53b115549..6a0df61ac182f 100644 --- a/datafusion/sql/src/unparser/dialect.rs +++ b/datafusion/sql/src/unparser/dialect.rs @@ -31,10 +31,10 @@ pub trait Dialect { pub struct DefaultDialect {} impl Dialect for DefaultDialect { - fn identifier_quote_style(&self, _identifier: &str) -> Option { + fn identifier_quote_style(&self, identifier: &str) -> Option { let identifier_regex = Regex::new(r"^[a-zA-Z_][a-zA-Z0-9_]*$").unwrap(); - if ALL_KEYWORDS.contains(&_identifier.to_uppercase().as_str()) - || !identifier_regex.is_match(_identifier) + if ALL_KEYWORDS.contains(&identifier.to_uppercase().as_str()) + || !identifier_regex.is_match(identifier) { Some('"') } else {