Did you know ... Search Documentation:
Packs (add-ons) for SWI-Prolog

Package "purity"

Title:A Horn Clause Only library for Prolog
Rating:Not rated. Create the first rating!
Latest version:0.2.1
SHA1 sum:16953fc3d470109e9786aa6fef7ae4a3719cfd89
Author:Neil Hoskins https://buslogic.pro
Maintainer:Neil Hoskins https://buslogic.pro
Packager:Neil Hoskins https://buslogic.pro
Home page:https://github.com/da-poodle/purity
Download URL:https://github.com/da-poodle/purity/releases/*.git

Reviews

No reviews. Create the first review!.

Details by download location

VersionSHA1#DownloadsURL
0.1.0009edfb0f20ae3f44a39922bf3c9b545582a5c3d1https://github.com/da-poodle/purity.git
0.1.145b5da96fa18f3b8d71de3133e3d85bf508e9a6e1https://github.com/da-poodle/purity.git
0.1.2befff9fba916dccf5fb7d3feefe8d9435f8dadc91https://github.com/da-poodle/purity.git
0.1.35269b612545c30612804554e7e0eb434280ff82c10https://github.com/da-poodle/purity.git
0.2.116953fc3d470109e9786aa6fef7ae4a3719cfd891https://github.com/da-poodle/purity.git

Purity

A Horn Clause only library for Prolog.

For more detailed documentation and API reference see: https://buslogic.pro/content/purity

Overview

Prolog was designed with a minimal set of operations and structures in mind, the following is all you need to make up any Turing Complete program:

  • Atoms:
    • a
    • 12
    • 'Hello, World'
  • Compound terms
    • a(b)
    • person('Fred', age(23), gender(male))
  • Variables:
    • A
    • Varname
  • Facts:
    • mortal(socrates).
  • Rules:
    • alive(X) :- not_dead(X).
  • Conjunctions:
    • A, B.
  • Disjunctions:
    • A ; B.
  • True
  • Fail The modern Prolog language has added a number of new operations on top of these, but they all involve using the cut (!) operator, which is impure.

    Purity aims to implement ways to do the same things as Prolog programs that use a cut operator, but by only using the basic Horn clause opererations.

Contents of pack "purity"

Pack contains 11 files holding a total of 50.6K bytes.