mirror of
https://github.com/khibino/haskell-relational-record.git
synced 2024-12-15 06:43:04 +03:00
Remove redundant definition.
This commit is contained in:
parent
e5e5d246d0
commit
9fb5a74317
@ -83,13 +83,13 @@ sqlTermsString = d where
|
||||
d ([c]) = c
|
||||
d (cs) = paren $ intercalate ", " cs
|
||||
|
||||
-- | SQL expression strings which represent projection.
|
||||
sqlStringOfProjection :: Projection c r -> String
|
||||
sqlStringOfProjection = sqlTermsString . map stringFromColumnSQL . columns
|
||||
-- | Unsafely get SQL term from 'Proejction'.
|
||||
unsafeShowSqlProjection :: Projection c r -> String
|
||||
unsafeShowSqlProjection = sqlTermsString . map stringFromColumnSQL . columns
|
||||
|
||||
-- | 'Expr' from 'Projection'
|
||||
exprOfProjection :: Projection c r -> Expr c r
|
||||
exprOfProjection = UnsafeExpr.Expr . sqlStringOfProjection
|
||||
exprOfProjection = UnsafeExpr.Expr . unsafeShowSqlProjection
|
||||
|
||||
-- | Project from Projection type into expression type.
|
||||
expr :: Projection p a -> Expr p a
|
||||
@ -153,10 +153,6 @@ unsafeShowSqlExpr = UnsafeExpr.showExpr
|
||||
instance ProjectableShowSql (Expr p) where
|
||||
unsafeShowSql = unsafeShowSqlExpr
|
||||
|
||||
-- | Unsafely get SQL term from 'Proejction'.
|
||||
unsafeShowSqlProjection :: Projection c r -> String
|
||||
unsafeShowSqlProjection = sqlStringOfProjection
|
||||
|
||||
-- | Unsafely get SQL term from 'Proejction'.
|
||||
instance ProjectableShowSql (Projection c) where
|
||||
unsafeShowSql = unsafeShowSqlProjection
|
||||
|
Loading…
Reference in New Issue
Block a user