fix(api): point query_as!/query_scalar! param comments at #137#153
Merged
StefanSteiner merged 2 commits intoJun 16, 2026
Merged
Conversation
…au#137) query_as! / query_scalar! validate SQL and accept $N args but the QueryAs/QueryScalar runtime builders don't yet bind them (params stored as debug strings; fetch_* forward to the non-param fetch_*_as). Point the dead-code comment and a TODO at fetch_*_as_params (added in tableau#137) as the primitive that finishes parameter binding.
Remove stale 'W3' and 'future milestone' phrasing from QueryAs::new doc and QueryScalar::params allow-reason. Both now point at issue tableau#137 and the _as_params delegation target, consistent with the QueryAs::params comment updated in the prior commit.
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Updates stale comments in
query_as.rsthat still reference "Milestone B (W3)"and "a future milestone" — phrasing from the original compile-time validator
plan that predates the actual implementation (shipped in v0.4.0).
The
query_as!/query_scalar!macros validate SQL and accept$Nbindarguments syntactically, but the runtime
QueryAs<T>/QueryScalar<T>buildersdon't actually bind them — params are stored as
format!("{p:?}")debug stringsand the
fetch_*methods forward to the non-paramfetch_*_as. This is theone remaining gap from the compile-time validator work.
Issue #137 (merged in #152) added
fetch_one_as_params/fetch_all_as_params/stream_as_params— exactly the runtime primitive needed to finish the binding.These comments now point there so the connection isn't lost.
Changes
QueryAs::paramscomment: explains why it's dead + namesfetch_*_as_paramsas the delegation target.
QueryAs::params#[allow(dead_code, reason = …)]: updated from stale"Milestone B (W3)" to "not yet wired — see issue Add parameterized FromRow methods (fetch_one_as/fetch_all_as/stream_as + ToSqlParam params) #137".
QueryAs::newdoc: "typed binding will be tightened in W3" → points at theTODO(#137)onfetch_all.QueryAs::fetch_all: added// TODO(#137)marking the exact forwarding site.QueryScalar::params: added same-gap comment + aligned#[allow]reasonstring to match
QueryAs.Test plan
cargo clippy -p hyperdb-api --all-targets— clean (doc-only change)cargo build --workspace— green