Commit 932b743
committed
perf(database): skip numeric rewrites inside quoted SQL
Remove quoted values before number replacement so discarded digits do not
create intermediate strings. Outside numeric word boundaries stay unchanged.
Bun 1.4.1 focused medians in ns/op: short literal 681 to 502, long numeric
literal 12052 to 1339, prepared-query control 502 to 511. These are developer
laptop measurements, not an HTTP throughput claim.
Verified 337715 generated normalization cases, 1816 tests, framework types,
and lint. HTTP validation returned 367633 successful requests with matching
persisted query logs. Added quote-boundary cases and a persistence assertion
containing digits inside a quoted value.1 parent d09349e commit 932b743
3 files changed
Lines changed: 11 additions & 5 deletions
File tree
- storage/framework/core/database
- src
- tests
- fixtures
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
133 | 133 | | |
134 | 134 | | |
135 | 135 | | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
136 | 141 | | |
137 | 142 | | |
138 | 143 | | |
139 | 144 | | |
140 | | - | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | 145 | | |
145 | 146 | | |
146 | 147 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
106 | 106 | | |
107 | 107 | | |
108 | 108 | | |
109 | | - | |
| 109 | + | |
110 | 110 | | |
111 | 111 | | |
112 | 112 | | |
| |||
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
6 | 11 | | |
7 | 12 | | |
8 | 13 | | |
| |||
0 commit comments