I hereby claim:
- I am coot on github.
- I am coot (https://keybase.io/coot) on keybase.
- I have a public key ASA4C4mk10e3x-LowdhnXeF8_qd8-tK_UhiEfw47z8u6zwo
To claim this, I am signing this object:
{-# LANGUAGE DataKinds #-} | |
{-# LANGUAGE TypeSynonymInstances #-} | |
{-# LANGUAGE FlexibleInstances #-} | |
{-# LANGUAGE TypeApplications #-} | |
{-# LANGUAGE FlexibleContexts #-} | |
{-# LANGUAGE TypeOperators #-} | |
{-# LANGUAGE DeriveGeneric #-} | |
{-# LANGUAGE BangPatterns #-} | |
{-# LANGUAGE UndecidableInstances #-} | |
{-# LANGUAGE DerivingStrategies #-} |
module Synchronisation where | |
import Control.Concurrent | |
import Control.Concurrent.STM.TMVar | |
import Control.Monad.STM | |
newtype LastToFinishSTM a = LastToFinishSTM { runLastToFinish :: STM a } | |
instance Semigroup (LastToFinishSTM a) where |
{-# LANGUAGE DataKinds #-} | |
{-# LANGUAGE DerivingStrategies #-} | |
{-# LANGUAGE DerivingVia #-} | |
{-# LANGUAGE EmptyCase #-} | |
{-# LANGUAGE FlexibleInstances #-} | |
{-# LANGUAGE GADTs #-} | |
{-# LANGUAGE PatternSynonyms #-} | |
{-# LANGUAGE PolyKinds #-} | |
{-# LANGUAGE RankNTypes #-} | |
{-# LANGUAGE StandaloneDeriving #-} |
" Author: Marcin Szamotulski, © 2012-2020 | |
" License: Vim-License, see :help license | |
fun! ViewPort(cmd, s_line, e_line, ...) " {{{1 | |
if !has("autocmd") | |
echohl WarningMsg | |
echom "[ViewPort]: requires +autocmd feature" | |
echohl Normal | |
return | |
endif |
{-# LANGUAGE NamedFieldPuns #-} | |
-- | https://en.wikipedia.org/wiki/Flip-flop_(electronics)#SR_NOR_latch | |
module FlipFlops | |
( -- * Logic primitives | |
-- * SR-NOR--Latch | |
SRNORLatch | |
, mkSRNORLatch | |
, runSRNORLatch | |
-- ** SR-NAND--Latch |
" Simple DWM like window managment for vim windows | |
fun! WinFocus(winnr) | |
" this assumes that windows have a two column layer: master windows on the | |
" left, and right column consists of a list of opened windows | |
if a:winnr == 0 | |
let l:winnr = winnr() | |
else | |
let l:winnr = a:winnr | |
endif | |
if l:winnr == 1 |
{-# LANGUAGE GADTs #-} | |
{-# LANGUAGE RankNTypes #-} | |
{-# LANGUAGE ScopedTypeVariables #-} | |
import Prelude hiding (filter, (.)) | |
import Control.Arrow | |
import Control.Category | |
data TracerC c a where |
module Naturals where | |
-- based on https://plfa.github.io/ | |
import Relation.Binary.PropositionalEquality as Eq | |
open Eq using (_≡_; refl; cong; sym; trans) | |
open Eq.≡-Reasoning using (begin_; _≡⟨⟩_; _≡⟨_⟩_; _∎) | |
data ℕ : Set where | |
zero : ℕ |
I hereby claim:
To claim this, I am signing this object:
module Main where | |
import Prelude | |
import Data.Foldable (fold, elem) | |
import TryPureScript | |
import Type.Row (class ListToRow, class RowToList, Cons, Nil, kind RowList) | |
import Type.Proxy (Proxy(..)) | |
import Type.Data.Symbol (class IsSymbol, reflectSymbol) | |
import Data.Array (cons) | |
import Data.Monoid (mempty) |