on dev help sign in
Unconstrain
commit992e55a925b774899e422ffd010dba751a38a96e authorEitan Chatav <eitan.chatav@gmail.com> dateTue 7 Nov 2017, 14:15 (9 years ago) parentba4864f
1 file changed+4
squeal-postgresql/src/Squeal/PostgreSQL/Schema.hs+4
squeal-postgresql/src/Squeal/PostgreSQL/Schema.hs+4
@@ -71,6 +71,7 @@ module Squeal.PostgreSQL.Schema
7171 , SameFields
7272 -- * PostgreSQL Constraints
7373 , (:=>)
74+ , Unconstrain
7475 , ColumnConstraint (..)
7576 , DropDefault
7677 , DropDefaultList
@@ -334,6 +335,9 @@ type family SameFields
334335
335336type (:=>) constraints ty = '(AsSet constraints,ty)
336337
338+type family Unconstrain constrained where
339+ Unconstrain '(constraints, ty) = '( '[], ty)
340+
337341data ColumnConstraint
338342 = Default
339343 | Unique