Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/suzannesoy/anaphoric
Anaphoric macros for racket
https://github.com/suzannesoy/anaphoric
racket-library
Last synced: 23 days ago
JSON representation
Anaphoric macros for racket
- Host: GitHub
- URL: https://github.com/suzannesoy/anaphoric
- Owner: SuzanneSoy
- License: cc0-1.0
- Created: 2016-04-08T10:17:08.000Z (over 8 years ago)
- Default Branch: main
- Last Pushed: 2021-07-29T01:08:48.000Z (over 3 years ago)
- Last Synced: 2024-10-10T20:08:59.683Z (28 days ago)
- Topics: racket-library
- Language: Racket
- Homepage: http://docs.racket-lang.org/anaphoric/
- Size: 61.5 KB
- Stars: 8
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE-more.md
Awesome Lists containing this project
README
[![Build Status,](https://img.shields.io/travis/jsmaniac/anaphoric/main.svg)](https://travis-ci.org/jsmaniac/anaphoric)
[![Coverage Status,](https://img.shields.io/codecov/c/github/jsmaniac/anaphoric/main.svg)](https://codecov.io/gh/jsmaniac/anaphoric)
[![Build Stats,](https://img.shields.io/badge/build-stats-blue.svg)](http://jsmaniac.github.io/travis-stats/#jsmaniac/anaphoric)
[![Online Documentation,](https://img.shields.io/badge/docs-online-blue.svg)](http://docs.racket-lang.org/anaphoric/)
[![Maintained as of 2021,](https://img.shields.io/maintenance/yes/2021.svg)](https://github.com/jsmaniac/anaphoric/issues)
[![License: CC0 v1.0.](https://img.shields.io/badge/license-CC0-blue.svg)](https://creativecommons.org/publicdomain/zero/1.0/)anaphoric
=========Anaphoric conditional forms for `racket`:
```
(aif (member 'a lst)
(displayln it)
(displayln "not found")) ;; Can't use "it" in the else clause.(awhen (member 'a lst)
(displayln it))(acond
[(member 'a lst) (displayln it)]
[(member 'b lst) (displayln it)]
[else (displayln "not found")]) ;; Can't use "it" in the else clause.
```This package also provides hygienic versions:
```
(if-let [x (member 'a lst)]
(displayln x)
(displayln "not found")) ;; Can't use "x" in the else clause.(when-let [x (member 'a lst)]
(displayln it))(cond-let x
[(member 'a lst) (displayln x)]
[(member 'b lst) (displayln x)]
[else (displayln "not found")]) ;; Can't use "x" in the else clause.
```Installation
------------```
raco pkg install --deps search-auto anaphoric
```