fix: Evaluation

This commit is contained in:
Tibo De Peuter 2025-04-06 17:29:23 +02:00
parent d702b9b081
commit 1acd1cfb67
Signed by: tdpeuter
GPG key ID: 38297DE43F75FFE2
17 changed files with 189 additions and 120 deletions

View file

@ -1,6 +1,6 @@
package prolog.components.expressions
import prolog.Substitution
import prolog.Substituted
import prolog.components.Provable
import prolog.components.terms.Atom
import prolog.components.terms.CompoundTerm
@ -13,7 +13,7 @@ abstract class Operator(
val leftOperand: Operand? = null,
val rightOperand: Operand
) : CompoundTerm(symbol, listOfNotNull(leftOperand, rightOperand)), Provable {
abstract override fun prove(): Sequence<Substitution>
abstract override fun prove(subs: Substituted): Sequence<Substituted>
override fun toString(): String {
return when (leftOperand) {