prowdsponsor / esqueleto

Bare bones, type-safe EDSL for SQL queries on persistent backends.
http://hackage.haskell.org/package/esqueleto
BSD 3-Clause "New" or "Revised" License
177 stars 51 forks source link

Add `ToBaseId` #130

Closed pseudonom closed 8 years ago

pseudonom commented 8 years ago

I couldn't put toBaseId inside Esqueleto because that would have created a cyclic dependency.

meteficha commented 8 years ago

Does it need a cyclic dependency even when translating the type signature from SqlExpr to expr, etc?

pseudonom commented 8 years ago

I believe veryUnsafe... forces SqlExpr rather than expr on us.

meteficha commented 8 years ago

But that would be part of the implementation that lives on the class instance, right?

pseudonom commented 8 years ago

Ah, yup.

pseudonom commented 8 years ago

Amended. Should ToBaseId get exported in Database.Esqueleto too?

meteficha commented 8 years ago

Yes, one can't really use one without the other.

pseudonom commented 8 years ago

kk, wasn't exactly sure what your Internal policy was.

pseudonom commented 8 years ago

This good to go? Can you just drop https://github.com/pseudonom/esqueleto/commit/a104b30da2494b9258f5575c62b2d43957be41b1 when you merge it?

meteficha commented 8 years ago

Released as esqueleto-2.4.3, thanks!

pseudonom commented 8 years ago

Great! Thanks.