{"size": 1674, "ext": "scrbl", "max_stars_repo_path": "scribblings/cclp.scrbl", "max_stars_repo_name": "v-for-vincent/racket-control-compiler", "max_stars_repo_stars_event_min_datetime": "2017-06-03T19:55:16.000Z", "max_stars_repo_stars_event_max_datetime": "2017-06-03T19:55:16.000Z", "max_issues_repo_path": "scribblings/cclp.scrbl", "max_issues_repo_name": "v-nys/cclp", "max_issues_repo_issues_event_min_datetime": "2017-04-11T08:13:36.000Z", "max_issues_repo_issues_event_max_datetime": "2018-04-18T13:16:06.000Z", "max_forks_repo_path": "scribblings/cclp.scrbl", "max_forks_repo_name": "v-for-vincent/racket-control-compiler", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": 1, "max_issues_count": 58, "max_forks_count": null, "avg_line_length": 33.48, "max_line_length": 165, "alphanum_fraction": 0.7461170848}
#lang scribble/manual
@(require (for-label racket))@;so that racket bindings are hyperlinked

@title{The CCLP language}
@author{Vincent Nys}
@defmodulelang{cclp}

CCLP is a language for the implementation of pure logic programs which rely on instantiation-based coroutining.
A program written in the CCLP language can be executed to generate --- at the current time --- an abstract interpretation of a pure logic program.
From this abstract interpretation, a logic program which does not require special coroutining constructs but which does have the desired control flow can be derived.

@section{A simple example}
@verbatim{
#lang reader "cclp-reader.rkt"
{PROGRAM}
sort(X,Y) :- perm(X,Y),ord(Y).

perm([],[]).
perm([X|Y],[U|V]) :- del(U,[X|Y],W),perm(W,V).

ord([]).
ord([X]).
ord([X,Y|Z]) :- lte(X,Y),ord([Y|Z]).

{FULL EVALUATION}
lte(γ1,γ2).
del(α1,[γ1|γ2],α2) -> α1/γ3,α2/γ4.

{PREPRIOR}
perm(γ1,α1),ord(α1)
perm(γ1,α1),ord([γ1|α1])
ord([γ1,γ2|α1]),perm(γ1,α1)

{QUERY}
sort(γ1,α1)
}

@;include-section["interaction.scrbl"]
@;include-section["abstract-substitution.scrbl"]
@;include-section["abstract-domain-ordering.scrbl"]
@include-section["abstract-multi-domain.scrbl"]
@include-section["genealogical-graph.scrbl"]
@;include-section["abstract-analysis.scrbl"]

@section{Limitations}

@section{Plans for the future}
The current implementation allows the user to build an abstract analysis tree of the logic program.
From this analysis tree, a concrete Prolog program or CHR program can be synthesized, as described in @;TODO
Once the completeness properties of the abstract analysis have been proven, the goal will be to automate both synthesis procedures, as well.