Skip to content

Instantly share code, notes, and snippets.

@chiroptical
chiroptical / babyShark.hs
Last active February 3, 2023 15:23
Baby shark as a Haskell program
{-# LANGUAGE BlockArguments #-}
module Main where
main :: IO ()
main = do
babyShark
do do do do do do babyShark
do do do do do do babyShark
do do do do do do babyShark
@TOTBWF
TOTBWF / ObfuscatedSKI.hs
Last active February 23, 2023 06:29
A Lambda Expression to SKI Combinator compiler, written entirely using SKI combinators.
This file has been truncated, but you can view the full file.
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE ImpredicativeTypes #-}
{-# LANGUAGE TemplateHaskell #-}
module ObfuscatedSKI where
import Unsafe.Coerce (unsafeCoerce)
--------------------------------------------------------------------------------
-- A Lambda to SKI Combinator Compiler, written entirely using SKI Combinators
--
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include <X11/Xlib.h> /* of course */
#include <X11/Xutil.h> /* duuuh */
#include <sys/ipc.h>
#include <sys/shm.h>
#include <X11/extensions/XShm.h> /* obviously */
@CMCDragonkai
CMCDragonkai / nix_string_and_path_concatenation.md
Last active May 17, 2024 17:37
Nix: String and Path Concatenation #nix #nixos

Nix String and Path Concatenation

From Bas van Dijk:

To understand these things I would recommend using nix-repl:

$ nix-repl
Welcome to Nix version 1.11.2. Type :? for help.