Provide witness for the sum-type structure of GenericResult
authorKlaus Aehlig <aehlig@google.com>
Fri, 14 Jun 2013 13:47:55 +0000 (15:47 +0200)
committerKlaus Aehlig <aehlig@google.com>
Mon, 17 Jun 2013 14:36:27 +0000 (16:36 +0200)
commitb74ebe4402ca4a2b2d9b225d75698c3bf96ecd40
tree97f5049de46806a562d0f74bf4ff4eee48863bb2
parent02312a1ae47612e0a6e7ddf3dfb079476f999630
Provide witness for the sum-type structure of GenericResult

GenericResult, while rightfully a type of its own, is isomorphic
to Either. So, also provide the case analysis function (i.e., the
universal arrow out of the sum).

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Michele Tartara <mtartara@google.com>
src/Ganeti/BasicTypes.hs