case class Person(id: Long, name: String, organizationId: Long)
object Person {
def groupByOrg: Map[Long, Seq[Person]] = ...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE GADTs #-} | |
module Main where | |
import Control.Monad | |
import Control.Monad.RWS.Strict | |
import Control.Monad.Trans.Error | |
import Control.Monad.Operational.Simple | |
import Prelude hiding (putChar, getChar) | |
import qualified System.IO as IO |
更新: | 2013-02-06 |
---|---|
バージョン: | 1.0.1 |
作者: | @voluntas |
URL: | http://voluntas.github.com/ |
変更履歴
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(use 'clojure.core.logic) | |
(defne append [x y z] | |
([() a a]) | |
([[a . b] _ [a . c]] | |
(append b y c))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE NoImplicitPrelude, MultiParamTypeClasses, Rank2Types, TypeOperators #-} | |
newtype Id a = | |
Id a | |
data a :\/ b = | |
Left a | |
| Right b | |
data a :/\ b = |