Skip to content

Instantly share code, notes, and snippets.

Nikos Baxevanis moodmosaic

View GitHub Profile
moodmosaic / stack.yaml
Last active Nov 1, 2018
Semigroup Laws
View stack.yaml
- hedgehog-0.6.1
moodmosaic / TH.hs
Last active Apr 30, 2018
Parametrised unit tests and Template Haskell
View TH.hs
{-# LANGUAGE TemplateHaskell #-}
module Discordia.TH where
import Language.Haskell.Extract (functionExtractorMap)
import Language.Haskell.TH
import Test.Framework (defaultMain)
import Test.HUnit (Test(..))
discover :: ExpQ
View SumProduct.hs
module SumProduct (
KnownColor (..)
, RGB (..)
, redColor
, magenta
, red
) where
View Visual FSharp VS 2017

Things that could actually be improved

We couldn’t find that file to show.
moodmosaic / Main.hs
Created May 25, 2017
Servant example from "Write a client library for any web API in 5 minutes"
View Main.hs
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
import Control.Applicative
import Control.Monad
import Control.Monad.IO.Class
import Control.Monad.Trans.Except
import Data.Aeson
View Sort
# Last checked
# $ date
# Mon Feb 27 23:59:15 EEST 2017
moodmosaic / gist:a1a4509f76f4f1d7a9b3e4149ce40ef4
Created Dec 7, 2016
Algebraic data types and mathematical reasoning
View gist:a1a4509f76f4f1d7a9b3e4149ce40ef4
Power of mathematics: Reasoning about functional types
The algebra (and calculus!) of algebraic data types
Algebraic type sizes and domain modelling
View Booking.cabal
name: Booking
synopsis: Handling a reservation request in Haskell. Proof of concept
description: Please see
license: MIT
license-file: LICENSE
author: Mark Seemann
copyright: 2016 Mark Seemann
View LightCheck.fs
// Port of Haskell
// -
// -
namespace LightCheck
/// <summary>
/// This module deals with the common task of pseudo-random number generation.
/// It makes it possible to generate repeatable results, by starting with a
/// specified initial random number generator, or to get different results on
You can’t perform that action at this time.