This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(define zip | |
X [] -> [] | |
[] Y -> [] | |
X Y -> (zip-help X Y [])) | |
(define zip-help | |
X Y Acc -> (reverse Acc) where (or (empty? X) (empty? Y)) | |
[X | Xs] [Y | Ys] Acc -> (zip-help Xs Ys [(@p X Y) | Acc])) | |
(define substitute |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\* This script is aimed to run on Shen 7.1 on any Common Lisp port *\ | |
(package property-vector-utilities- [delete-properties] | |
(define delete-properties | |
Ref Properties Vec -> (let Pos (hash Ref (limit Vec)) | |
Content (trap-error (<-vector Vec Pos) (/. (protect E) (error "no vector element to retract"))) | |
DeprecatedEntries (map (/. X [Ref X]) Properties) | |
NewContent (remove-entries DeprecatedEntries Content) | |
(do (vector-> Vec Pos NewContent) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\* This script is aimed to run on Shen 7.1 on any Common Lisp port *\ | |
(load "cl-destroy.shen") | |
(load "cl-define.shen") | |
\* old behavior *\ | |
(do (output "*** OLD BEHAVIOR ***~%") start) | |
(define sad-foo X -> (sad-bar X)) | |
(define sad-bar X Y -> (+ X Y)) | |
(trap-error ((sad-foo 5) 2) (/. E (do (output "+++expected error on CL: ~A+++~%" (error-to-string E)) expected-error))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\* This script is aimed to run on Shen 7.1 on any Common Lisp port *\ | |
\* (load "cl-destroy.shen") *\ | |
\* BEGIN: fast prototyping solution for partial application compatible define *\ | |
(package cl-define [caller-list cc-define] | |
\* vectors util from vectors library *\ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\* This script is aimed to run on Shen 7.1 on any Common Lisp port *\ | |
(package cl-destroy- [destroy-it] | |
(define simple-retract | |
X Vec -> (let Pos (hash X (limit Vec)) | |
(vector-> Vec Pos (fail)))) | |
(define retract | |
X Vec -> (let Pos (hash X (limit Vec)) | |
Content (trap-error (<-vector Vec Pos) (/. (protect E) (error "no vector element to rectract"))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" .vimrc | |
if has('win32') || has('win64') | |
set runtimepath=$HOME/.vim,$VIM/vimfiles,$VIMRUNTIME,$VIM/vimfiles | |
if has('gui_running') | |
if filereadable("C:\\Windows\\Fonts\\DejaVuSansMono.ttf") | |
set guifont=DejaVu_Sans_Mono:h10 | |
elseif | |
set guifont=Consolas:h9:cANSI | |
endif | |
endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (("€").length === 3) | |
{ | |
// UCS2 is not normal encoding | |
// suppose well-formed UTF-8 is used | |
// should work with SpiderMonkey multibytes representation | |
function string_$gt$n(str) | |
{ | |
fB=str.charCodeAt(0); | |
return (fB < 128) ? fB : |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\* functions to read UTF-8 files & sequences *\ | |
(synonyms bytelist (list number)) | |
(define nlist->utf8 | |
{ (list number) --> bytelist } | |
[] -> [] | |
X -> (nlist->utf8- X [])) | |
(define nlist->utf8- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\* Build Lisp CxRS *\ | |
\* CC Part *\ | |
(defcc <expr> X <expr> := [X | <expr>]; <e> := [];) | |
(defcc <a-d-to-head-tail> | |
"a" <a-d-to-head-tail> := [head <a-d-to-head-tail>]; | |
"d" <a-d-to-head-tail> := [tail <a-d-to-head-tail>]; | |
"r" <expr> := <expr>;) | |
(defcc <cxr?> | |
"c" "a" <a-d-to-head-tail> := [head <a-d-to-head-tail>]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; MY STUMPWM | |
(in-package :stumpwm) | |
(setq *mouse-focus-policy* :click) | |
(setf *startup-message* | |
"everything seems to be just fine") | |
(set-contrib-dir "/home/sleeze/.config/stumpwm/contrib") | |
(setf *suppress-frame-indicator* t) | |
;; Directories |