Skip to content
Commit Detail

Commit 1da3c7e

Author
Kenton Varda <kenton@cloudflare.com> 2024-10-22 10:37:51 -0500
Parents
e9df309
Tree
0604f69
SQLite: Refactor: Have Cursor::iteratorImpl() convert all the way to JsValue.

This is much cleaner as `SqlValue` may contain pointers that are invalidated when we iterate the statement. Previously, we were counting on such iteration not happening before JSG had a chance to convert the values to JavaScript, which was a little precarious.

This will also allow us -- in a later commit -- to implement an optimization where we iterate the statement more eagerly.

With this change, the logic of `wrapSqlRow{,Raw}()` ends up being merged into `{row,raw}IteratorNext()` so the former can be deleted.

Files changed

2 files changed~2 modified