Skip to content

Instantly share code, notes, and snippets.

View jonsterling's full-sized avatar

Jon Sterling jonsterling

View GitHub Profile
@jozefg
jozefg / russell.jonprl
Last active August 29, 2015 14:27
A proof that Type cannot be of type Type in JonPRL.
Operator Russell : ().
[Russell] =def= [{x : U{i} | not(member(x; x))}].
Tactic break-plus {
@{ [x : _ + _ |- _] => elim <x> }
}.
Theorem u-in-u-wf : [member(member(U{i}; U{i}); U{i'})] {
unfold <member>; eq-eq-base; unfold <bunion>; auto;
csubst [ceq(U{i}; lam(x.snd(x)) pair(inr(<>); U{i}))]
@AndrasKovacs
AndrasKovacs / GluedEval.hs
Last active January 20, 2025 21:55
Non-deterministic normalization-by-evaluation in Olle Fredriksson's flavor.
{-# language Strict, LambdaCase, BlockArguments #-}
{-# options_ghc -Wincomplete-patterns #-}
{-
Minimal demo of "glued" evaluation in the style of Olle Fredriksson:
https://github.com/ollef/sixty
The main idea is that during elaboration, we need different evaluation
@juliensagot
juliensagot / AquaScrollBar.swift
Created February 16, 2025 14:17
Aqua scroll bar in SwiftUI
import SwiftUI
struct AquaScrollBar: View {
@ScaledMetric private var height = 35.0
var body: some View {
Track()
.frame(height: height)
.overlay(alignment: .leading) {
Thumb()