yesodweb / yesodweb/persistent
derivePersistField phantom type support
Open
@juanpaucar is already working on this.
Since Oct 29, 2020.
Feature Request
good first issue
- Dominant language
- Haskell
- Stars
- 486
- Forks
- 306
- PR merge metrics
- No merged PRs in 30d
Description
Phantom types are very useful for tagging things on type level, but at the moment this code will not compile
-- @Employment.hs
{-# LANGUAGE TemplateHaskell #-}
module Employment where
import Database.Persist.TH
import Prelude
data Employment a = Employed | Unemployed | Retired
deriving (Show, Read, Eq)
derivePersistField "Employment a"
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.