Journal article
Backtracking, interleaving, and terminating monad transformers
Abstract
We design and implement a library for adding backtracking computations to any Haskell monad. Inspired by logic programming, our library provides, in addition to the operations required by the MonadPlus interface, constructs for fair disjunctions, fair conjunctions, conditionals, pruning, and an expressive top-level interface. Implementing these additional constructs is easy in models of backtracking based on streams, but not known to be …
Authors
Kiselyov O; Shan C-C; Friedman DP; Sabry A
Journal
ACM SIGPLAN Notices, Vol. 40, No. 9, pp. 192–203
Publisher
Association for Computing Machinery (ACM)
Publication Date
September 12, 2005
DOI
10.1145/1090189.1086390
ISSN
0362-1340