Compile-time support for external drivers
Does your PR solve an issue?
Not on this repo, but it would solve an issue for the sqlx-exasol driver: https://github.com/bobozaur/sqlx-exasol/issues/9.
With the changes here, the compile-time macros can be redefined by external drivers through usage of sqlx_macros_core::query::expand_input() with a custom QueryDriver. Furthermore, a sqlx-cli like binary can be exposed as well, since the install_default_drivers() call was moved to the sqlx-cli binaries. With these changes, the custom driver binary (that depends on sqlx-cli as a library) can install its own driver (this would panic with the current state of things).
Is this a breaking change?
Nope, it's internal only. Should not affect anything else at all.
Here's the PR from sqlx-exasol that makes use of these changes to implement compile-time query support and sqlx-cli like behavior: https://github.com/bobozaur/sqlx-exasol/pull/35.
@bobozaur can you rebase and fix the conflict? We're ready to merge this.