Skip to content

Instantly share code, notes, and snippets.

View milibopp's full-sized avatar

Emilia Bopp milibopp

View GitHub Profile
@aarondewindt
aarondewindt / adt.py
Last active October 27, 2023 05:07
Experimental Algebraic Data Types implementation in Python 3.10
from dataclasses import dataclass
class ADTMeta(type):
def __new__(mcs, name, bases, namespace: dict):
adtc_class = super().__new__(mcs, name, bases, namespace)
if "__is_adt_variant__" in namespace:
if namespace["__is_adt_variant__"]:
return adtc_class
@joeblau
joeblau / git yolo
Created February 3, 2014 12:48
git yolo command
alias gityolo='git commit -am "DEAL WITH IT" && git push -f origin master'