Skip to content

Return a plain query_as! invocation in the case of no compile-time conditions #3

@kyrias

Description

@kyrias

Currently if we ended up having no compile-time conditional variation we end up creating a fake match expression so that the rest of the code can look the same. It would be nice if we could make the macro generate a simple query_as! without the whole map type indirection.

Using the conditional_query_as! macro can be useful even when there's no compile-time variability since it allows for referring to bound parameters by name rather than having to keep track and update the order of binding references manually.

// TODO: Think about whether we just return earlier in the pipeline and just return the
// original macro input as a `query_as!` macro.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions