interpl

Experiments with intepreters in Prolog
git clone https://ccx.te2000.cz/git/interpl
Log | Files | Refs | README

commit 29bbdbd755ecee81359f6df58604fedb9c19e11d
parent 2a7eeb651ce966b0c0928ac22c329625f32af87c
Author: Jan Pobrislo <ccx@te2000.cz>
Date:   Fri, 30 May 2025 17:15:36 +0000

tests for primitive(+)

Diffstat:
Mtests.pl | 3+++
1 file changed, 3 insertions(+), 0 deletions(-)

diff --git a/tests.pl b/tests.pl @@ -75,6 +75,9 @@ apply_example(`(cons ((help) this) (is very ((hard) to learn)))`, apply_example(`(cons (a b (c)) ())`, `((a b (c)))`). +apply_example(`(+ 0 0)`, `0`). +apply_example(`(+ 3 2)`, `5`). + test(apply_example, [forall(apply_example(Func, Args, ExpectedResult))]) :- interp_apply(primitive(Func), Args, Result), assertion(Result =@= ExpectedResult).