(define (^mint _bcom)
(define-values (decr-seal decr-unseal _decr-sealed?)
(make-sealer-triplet 'mint))
(define (^purse _bcom initial-balance)
(define-cell balance
initial-balance)
(define (<=-balance? amount)
(<= amount ($ balance)))
(define/contract (decr amount)
(-> (and/c integer? (>=/c 0) <=-balance?)
any/c)
($ balance (- ($ balance) amount)))
(define/contract (deposit-method amount src)
(-> (and/c integer? (>=/c 0)) any/c any/c)
((decr-unseal ($ src 'get-decr)) amount)
($ balance (+ ($ balance) amount)))
(methods
[(get-balance) ($ balance)]
[(sprout) (spawn ^purse 0)]
[deposit deposit-method]
[(get-decr) (decr-seal decr)]))
(define/contract (fiat-make-purse initial-balance)
(-> (and/c integer? (>=/c 0)) any/c)
(spawn ^purse initial-balance))
(methods [new-purse fiat-make-purse]))
(define (update from to)
(do ((y 0 (+ y 1)))
((= y grid-size))
(do ((x 0 (+ x 1)))
((= x grid-size))
(let* ((t (grid-ref from x y))
(t* (cond
((= t empty) empty)
((= t cu)
(if (<= 1 (neighbors from x y) 2) ehead cu))
((= t ehead) etail)
((= t etail) cu))))
(grid-set! to x y t*)))))
Guix build daemon + Goblins
(let* ((network-service (make-network-service))
(tor-service (make-tor-service #:network network-service)))
...)
Shepherd + Goblins
With Goblins! With Hoot!
See the donate button on https://spritely.institute
We are a 501(c)(3) nonprofit in the public interest!
They're REALLY COOL!