Error Message

Classification
Limitation

Discrepancy

The Jekejeke Prolog provides the same type errors as ISO Prolog. But Jekejeke Prolog only shows the sub term as a culprit when a type error occurs. But the ISO examples usually show the full term as a culprit. Further if a predicate has output parameters, we do not check their types. Instead we simply compute the output value and leave it to unification.

There are further problems with our error handling. The ISO core standard does not really mandate an order in checking the predicate arguments, but some of the examples imply a certain order. We should respect the same order in our test cases.

Also the ISO core standard provides a couple of internal data types that are derived from the usual Prolog data types. Among these we find the character which is an atom of length 1, and the byte which is an integer in the range 0 … 255. We do not yet correctly check these types, we first check for atom resp. integer, and then for the additional condition, yielding two different errors. The ISO core standard demands only one error.

Integration / Elimination

One reason for our simpler error messages is implementation effort and execution performance. Sub term error messages are easier to generate on the fly. They also give better information than argument based error messages. Omitting checking given output values results in higher execution speed.

Concerning the predicate arguments, we should check the error handling in all our predicates, and align it in case the usual order is not respected.

Further the error checking for character and byte should be fixed, so that it does not split up into an atom resp. integer checking, and a further addi-tional condition checking.

Failed Test Cases

ISO 7.8.3.4, ISO 6b
ISO 7.8.3.4, ISO 13
ISO 7.8.3.4, ISO 14
ISO 7.8.3.4, ISO 15
ISO 8.14.3.4, ISO 4
ISO 8.14.3.4, ISO 8
ISO 8.14.3.4, ISO 10
Corr.2 8.15.4.4, XLOG 3
Corr.2 8.15.4.4, XLOG 4
ISO 9.1.7, ISO 10
ISO 9.1.4, XLOG 5
ISO 9.1.7, ISO 5
ISO 9.1.7, ISO 20
ISO 9.1.7, ISO 28
ISO 9.1.7, ISO 9
Corr.2 9.1.3, XLOG 4
ISO 9.1.7, ISO 34
ISO 9.3.1.4, ISO 5
ISO 9.3.2.4, ISO 4
ISO 9.3.3.4, ISO 4
Corr.2 9.3.14.4, XLOG 3
Corr.2 9.3.12.4, XLOG 4
ISO 9.3.5.4, ISO 5
ISO 9.3.6.4, ISO 6
ISO 9.4.3.4, ISO 6
ISO 8.7.1.4, XLOG 1
ISO 8.7.1.4, XLOG 3
ISO 8.7.1.4, XLOG 4
ISO 8.7.1.4, XLOG 5
Corr.2 9.3.9, XLOG 1
ISO 8.5.3.4, ISO 9
ISO 8.5.1.4, ISO 16
ISO 8.5.1.4, ISO 17
ISO 8.5.2.4, ISO 11
ISO 8.16.1.4, ISO 7
Corr.2 8.4.4.4, XLOG 7
Corr.2 8.4.3.4, XLOG 6
ISO 8.13.3, ISO 4

Related Findings

Comments