From 00114d9674cc9b0d01ac25addbbb91a0a6c2dcd2 Mon Sep 17 00:00:00 2001 From: Nikita Sivukhin Date: Mon, 29 Sep 2025 11:00:19 +0400 Subject: [PATCH] remove quotes handling from normalization util --- core/util.rs | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/core/util.rs b/core/util.rs index e5ce1a613..255f1f357 100644 --- a/core/util.rs +++ b/core/util.rs @@ -112,16 +112,9 @@ const QUOTE_PAIRS: &[(char, char)] = &[ ]; pub fn normalize_ident(identifier: &str) -> String { - let quote_pair = QUOTE_PAIRS - .iter() - .find(|&(start, end)| identifier.starts_with(*start) && identifier.ends_with(*end)); - - if let Some(&(_, _)) = quote_pair { - &identifier[1..identifier.len() - 1] - } else { - identifier - } - .to_lowercase() + // quotes normalization already happened in the parser layer (see Name ast node implementation) + // so, we only need to convert identifier string to lowercase + identifier.to_lowercase().to_lowercase() } pub const PRIMARY_KEY_AUTOMATIC_INDEX_NAME_PREFIX: &str = "sqlite_autoindex_";