Revert "Support Rust expression like {x.y} in SQL strings"

This reverts commit b86d9321b5.
This commit is contained in:
gwenn
2023-08-21 19:40:37 +02:00
parent b86d9321b5
commit bbb570aabd
4 changed files with 7 additions and 34 deletions

View File

@@ -16,30 +16,7 @@ fn test_literal() -> Result {
let first_name = "El";
let last_name = "Barto";
let mut stmt = Stmt;
__bind!(stmt "SELECT $first_name, {last_name}");
Ok(())
}
#[test]
fn test_tuple() -> Result {
let names = ("El", "Barto");
let mut stmt = Stmt;
__bind!(stmt "SELECT {names.0}, {names.1}");
Ok(())
}
#[test]
fn test_struct() -> Result {
struct Person<'s> {
first_name: &'s str,
last_name: &'s str,
}
let p = Person {
first_name: "El",
last_name: "Barto",
};
let mut stmt = Stmt;
__bind!(stmt "SELECT {p.first_name}, {p.last_name}");
__bind!(stmt "SELECT $first_name, $last_name");
Ok(())
}