The slot-lambda package

[Tags: library, mit]

Write lambdas without naming the parameters. Example:

[s| ı : ı : _ı : ı : _ı : _ı : _0 : [] |] 'a' 'b' 'c'
=  (\x y z -> x:y:y:z:z:z:x:[]) 'a' 'b' 'c'
=  "abbccca"

The unicode character ı(305) representing a 'slot' can be input in vim with the digraph 'i.'

Just import Syntax.Slot and use either [s| ... |] or [slot| ... |], which are the same thing given two names just for convenience.


Properties

Versions0.1.0.0, 0.1.0.1, 0.1.0.2, 0.1.0.3
Dependenciesbase (>=4.6 && <5), containers (>=0.5.0.0), haskell-src-exts (>=1.14.0.1), haskell-src-meta (>=0.6.0.5), syb (>=0.4.1), template-haskell (>=2.8), vector (>=0.10.9.1)
LicenseMIT
Authorducis
Maintainerducis_cn@126.com
CategoryLanguage
Home pagehttps://github.com/ducis/pa_slot
Upload dateMon Apr 7 15:16:18 UTC 2014
Uploaded byducis
Downloads289 total (32 in last 30 days)

Modules

[Index]

Downloads

Maintainers' corner

For package maintainers and hackage trustees