Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/omentic/antiformatter
attempting to make the worst possible passable racket code
https://github.com/omentic/antiformatter
cursed racket
Last synced: about 2 months ago
JSON representation
attempting to make the worst possible passable racket code
- Host: GitHub
- URL: https://github.com/omentic/antiformatter
- Owner: omentic
- License: other
- Created: 2023-02-22T00:38:29.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-04-02T08:04:49.000Z (almost 2 years ago)
- Last Synced: 2024-11-02T12:42:36.374Z (3 months ago)
- Topics: cursed, racket
- Language: Racket
- Homepage:
- Size: 4.88 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# antiformatter
usage: `racket antifmt.rkt `
regular racket code. boring to read, easy on the eyes. booooooo
```rkt
(define (mangle sexp)
(if (not (list? sexp)) (error 'mangle "not an s-exp")
(if (empty? sexp) ""
(let ((paren (random-paren)))
(string-append
(first paren)
(mangle-params sexp)
(random-newline)
(last paren))))))
```anti-formatted racket code. exciting! an adventure to understand! still compiles (usually)
```rkt
[define [mangle sexp] [if (not [list? sexp
] ) [error {quote mangle } "not an s-exp"
] (if {empty? sexp} "" [let {{paren {random-paren
}
}
} [string-append {first paren } (mangle-params sexp) {random-newline } [last paren ] ]
])
]
]
```