Skip to content

Instantly share code, notes, and snippets.

@Gerstacker
Gerstacker / sphrect.scad
Created January 4, 2022 02:09
cutting fillet'ed holes in spherical shells
$fa=0.1;
$fs=2;
use <list-comprehension-demos/sweep.scad>
use <scad-utils/transformations.scad>
use <scad-utils/shapes.scad>
echo($vpr);
@Gerstacker
Gerstacker / ProxyRecordPlus.purs
Last active November 26, 2017 06:53
from (Proxy (Record ...)) to Record of empty Plus-conforming containers
module Data.Record.ProxyRecordPlus where
import Data.Record (insert)
import Type.Prelude (class IsSymbol, class RowLacks, class RowToList, RLProxy(RLProxy), SProxy(SProxy), RProxy)
import Type.Proxy (Proxy2(Proxy2))
import Type.Row (Cons, Nil, kind RowList)
import Control.Alternative (class Plus, empty)
class ProxyRecordArray (xs :: RowList) (row :: # Type) a (row' :: # Type) (m :: Type -> Type)
| xs -> row row' a
@Gerstacker
Gerstacker / ProxyRecordArray.purs
Last active November 26, 2017 06:17
from proxy to record of Arrays
module Data.Record.ProxyRecordArray where
import Data.Record (insert)
import Type.Prelude (class IsSymbol, class RowLacks, class RowToList, RLProxy(RLProxy), SProxy(SProxy), RProxy)
import Type.Row (Cons, Nil, kind RowList)
class ProxyRecordArray (xs :: RowList) (row :: # Type) a (row' :: # Type)
| xs -> row row' a
where
proxyRecordArrayImpl :: RLProxy xs -> Record row'