News for hackers. Stuff that matters.
Re:Rust-Query by kelnos on Saturday November 30, 2024 @06:04PM (#42284704)
I've used systems like this in Scala. It's actually pretty magical to write something like:

    val foos = sql"SELECT * from foos WHERE status = 'frobbed'".as[List[Foo]]
... and have the macro system parse the query at compile time and verify that the query will indeed return a `List[Foo]`.

I think this is a nice middle ground, but constructing dynamic queries often can't be checked at compile-time.

(I'm probably getting the syntax somewhat wrong; I haven't done Scala in quite a few years at this point.)

There are no comments on this comment yet.