fix: avoid lookbehind in application regexes for older WebKit

Application regex lookbehind prevented older WebKit from loading the startup module graph. Replace lookbehind with boundary checks across run/terminal links, SQL aliases, debugger targets and refactoring; preserve Unicode boundaries, UTF-16 offsets and empty-match progress. Add compatibility and regression tests.

Fixes #224
Refs #208
Цей коміт міститься в:
l0ng-ai authored and GitHub committed 2026-10-29 15:01:01 +08:00
1 джерело 364bb5ef50
коміт d37b96002b
10 files changed
+87 -10

No files matched your search

+1 -1
Переглянути файл
@@ -68,7 +68,7 @@ export function quoteIdent(name: string, driver: DbDriver): string {
/** A short alias for `table` not in `taken`: `order_items` → `oi`, `users` → `u`. */
export function aliasFor(table: string, taken: ReadonlySet<string>): string {
const words = table.split(/[_\s.$-]+|(?<=[a-z])(?=[A-Z])/).filter(Boolean);
const words = table.replace(/([a-z])([A-Z])/g, "$1 $2").split(/[_\s.$-]+/).filter(Boolean);
let base =
words
.map((w) => w[0]!)