commonMain.it.unibo.tuprolog.solve.stdlib.DefaultBuiltins.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of solve-classic-metadata Show documentation
Show all versions of solve-classic-metadata Show documentation
Stable, state-machine-based implementation of Prolog's SLDNF resolution principle
package it.unibo.tuprolog.solve.stdlib
import it.unibo.tuprolog.solve.Signature
import it.unibo.tuprolog.solve.library.AliasedLibrary
import it.unibo.tuprolog.solve.primitive.Primitive
import it.unibo.tuprolog.solve.stdlib.primitive.Throw
import it.unibo.tuprolog.solve.stdlib.rule.SpecificRules
import it.unibo.tuprolog.theory.Theory
object DefaultBuiltins : AliasedLibrary by CommonBuiltins {
override val theory: Theory by lazy {
CommonBuiltins.theory + SpecificRules.theory
}
override val primitives: Map by lazy {
CommonBuiltins.primitives + sequenceOf(
Throw
).map { it.descriptionPair }.toMap()
}
}