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
(... | |
'(org-export-backends (quote (ascii html))) | |
'(org-html-checkbox-type (quote html)) | |
'(org-html-head-extra | |
"<style type=\"text/css\"> | |
:root {--serif-font: serif; --sans-serif-font: sans-serif; --monospace-font: monospace; } | |
body { margin:40px auto; max-width:700px; line-height:1.6; font-size:18px; color:#444; padding:0 10px; } | |
h1 { font-family: var(--serif-font); } | |
h2,h3,h4,h5 { font-family: var(--sans-serif-font); } | |
.section-number-2,.section-number-3,.section-number-4,.section-number-5 { margin-right: 0.5em; } |
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 std::fmt::Debug; | |
#[derive(Debug)] | |
pub enum EPrim<'a> { | |
Id, | |
Lit(f64), | |
Vec(&'a Vec<f64>), | |
Add, | |
Mul, | |
Sub, |
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
{-# OPTIONS_GHC -Wall #-} | |
{-# LANGUAGE DataKinds #-} | |
{-# LANGUAGE LambdaCase #-} | |
{-# LANGUAGE FlexibleContexts #-} | |
{-# LANGUAGE FlexibleInstances #-} | |
{-# LANGUAGE GADTs #-} | |
{-# LANGUAGE PolyKinds #-} | |
{-# LANGUAGE ScopedTypeVariables #-} | |
{-# LANGUAGE StandaloneDeriving #-} |
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
import Data.Fin | |
import Data.Vect | |
import Vec | |
dotprod : Array [S n] Integer -> Array [S n] Integer -> Array [] Integer | |
dotprod x y = reduce (binop (+)) (apply_binary (lift $ binop (*)) x y) | |
map : (Array dim a -> Array dim' b) -> Array (n :: dim) a -> Array (n :: dim') b | |
map f xs = apply_unary (lift (Sc f)) xs |
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
import prelude | |
import equiv | |
data nat | |
= zero | |
| suc (n : nat) | |
data fix (f : U -> U) = mk (x : f (fix f)) | |
data maybe (A : U) |
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
#!/bin/bash | |
set -e | |
# This is a MacOS compiant fork of https://github.com/phadej/binary-orphans/blob/master/hackage-docs.sh, | |
# which is a stack-enabled fork of https://github.com/ekmett/lens/blob/master/scripts/hackage-docs.sh | |
# :-) | |
if [ "$#" -ne 1 ]; then | |
echo "Usage: scripts/hackage-docs.sh HACKAGE_USER" | |
exit 1 |