Commit cd3bd5f
fix: track backtick-quoted identifiers in find_top_level_keyword
A column named after a reserved keyword (e.g. \`SOURCE\`) in a PRIMARY KEY
clause would pass both word-boundary checks since backtick satisfies
!p.is_alphanumeric() && p != '_', causing a false keyword split and spurious
drift detection. Add in_backtick state alongside in_single_quote/in_double_quote
so keyword scanning is suppressed inside backtick-quoted identifiers.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 3a5aaaf commit cd3bd5f
1 file changed
Lines changed: 20 additions & 2 deletions
Lines changed: 20 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
214 | 214 | | |
215 | 215 | | |
216 | 216 | | |
| 217 | + | |
217 | 218 | | |
218 | 219 | | |
219 | 220 | | |
| |||
230 | 231 | | |
231 | 232 | | |
232 | 233 | | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
233 | 240 | | |
234 | 241 | | |
235 | 242 | | |
236 | | - | |
237 | | - | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
238 | 246 | | |
239 | 247 | | |
| 248 | + | |
240 | 249 | | |
241 | 250 | | |
242 | 251 | | |
| |||
2354 | 2363 | | |
2355 | 2364 | | |
2356 | 2365 | | |
| 2366 | + | |
| 2367 | + | |
| 2368 | + | |
| 2369 | + | |
| 2370 | + | |
| 2371 | + | |
| 2372 | + | |
| 2373 | + | |
| 2374 | + | |
2357 | 2375 | | |
2358 | 2376 | | |
2359 | 2377 | | |
| |||
0 commit comments