Skip to content

Instantly share code, notes, and snippets.

View PatchMixolydic's full-sized avatar
🏳️‍🌈
lesbian beyond belief

Ruby Lazuli PatchMixolydic

🏳️‍🌈
lesbian beyond belief
View GitHub Profile
@PatchMixolydic
PatchMixolydic / try.rs
Last active February 23, 2023 21:22
`Try` trait design sketches for Laria
enum ControlFlow[B, C = ()] {
Break(B),
Continue(C),
}
trait Try {
type Break;
type Continue;
fn branch(self) -> ControlFlow[Self::Break, Self::Continue];
[build]
rustflags = ["-C", "link-args=-lc"]
; These are some ideas on how types might be represented in
; Nightbug, a Lisp based language.
; Option 1 uses inline types for functions and separates types from names with an infix colon
; The infix colon is a bit weird for a Lisp-like, but is congruent with other languages
; (Typed Racket (sometimes; notable for being a Lisp), Haskell, Rust) and with type theory.
;
; Option 2 uses inline types for functions and just represents types with a list of form
; (name Type). This might cause readability issues, especially with generics/type arguments.
;
; Option 3 uses out-of-line type signatures for functions and uses the infix colon notation.
@PatchMixolydic
PatchMixolydic / makeXComp.sh
Created February 23, 2020 01:43
Script to build a cross compiler
#!/bin/sh
cd ${HOME}
wget https://ftp.wayne.edu/gnu/binutils/binutils-2.34.tar.gz
wget https://ftp.gnu.org/gnu/gcc/gcc-9.2.0/gcc-9.2.0.tar.gz
tar -xf binutils-2.34.tar.gz
cd binutils-2.34
mkdir build && cd build
../configure --target=$TARGET --prefix="$PREFIX" --with-sysroot --disable-nls --disable-werror
make -j7
make install