Implementation of a variant of Dijkstras Guarded Command Language embedded in Wisp Scheme using Guile.

heads

tip
browse log

clone

read-only
https://hg.sr.ht/~arnebab/guarded-commands
read/write
ssh://hg@hg.sr.ht/~arnebab/guarded-commands
#+title: Guarded Commands in Wisp

Implementation of a variant of Dijkstras Guarded Command Language embedded in Wisp Scheme using Guile.

* Run

#+BEGIN_EXAMPLE
  ./guarded-commands.w -i
  wisp@(guile-user)> import : guarded-commands
#+END_EXAMPLE

Requires [[http://gnu.org/s/guile][Guile 2.2 or later]].

* Install from release

#+BEGIN_EXAMPLE
  ./configure && make && make install
#+END_EXAMPLE

* Install and develop from clone

#+BEGIN_EXAMPLE
  ./setup.sh # just autoreconf -i
  ./configure
  make && make install && make distcheck
#+END_EXAMPLE

Also see

#+BEGIN_EXAMPLE
  make help
#+END_EXAMPLE

* Copyright and License

Guarded Commands is built by Arne Babenhauserheide.

It is licensed under the AGPLv3 or later, so you can use it anyway you
see fit as long as you stick to the license and provide all who play it
with a way to access the source. See COPYING.AGPLv3

The source is located at https://hg.sr.ht/~arnebab/guarded-commands

* Examples

#+begin_src wisp
import : guarded-commands
define : euclidean a b
    while-any
         {a < b} : set! b {b - a}
         {b < a} : set! a {a - b}
    values a b
#+end_src

* Embedded in Scheme

To allow for use outside trivial examples, it is embedded in Wisp, a
Scheme dialect.

It is realized in Guile Scheme, the official GNU language for
extensions.