[ Reference Manual | Alphabetic Index ]

library(iso_strict)

Strict ISO Prolog compatibility library   [more]

Predicates

<(?, ?)
No description available
=:=(?, ?)
No description available
=<(?, ?)
No description available
=\=(?, ?)
No description available
>(?, ?)
No description available
>=(?, ?)
No description available
current_prolog_flag(?, ?)
No description available
is(?, ?)
No description available
open(?, ?, ?)
No description available
open(?, ?, ?, ?)
No description available
read_term(?, ?)
No description available
read_term(?, ?, ?)
No description available
set_prolog_flag(?, ?)
No description available
stream_property(?, ?)
No description available
write_term(?, ?)
No description available
write_term(?, ?, ?)
No description available

Reexports

reexport true / 0 from eclipse_language
reexport fail / 0 from eclipse_language
reexport ! / 0 from eclipse_language
reexport , / 2 from eclipse_language
reexport ; / 2 from eclipse_language
reexport -> / 2 from eclipse_language
reexport catch / 3 from eclipse_language
reexport = / 2 from eclipse_language
reexport \= / 2 from eclipse_language
reexport var / 1 from eclipse_language
reexport atom / 1 from eclipse_language
reexport integer / 1 from eclipse_language
reexport float / 1 from eclipse_language
reexport atomic / 1 from eclipse_language
reexport compound / 1 from eclipse_language
reexport nonvar / 1 from eclipse_language
reexport number / 1 from eclipse_language
reexport callable / 1 from eclipse_language
reexport ground / 1 from eclipse_language
reexport acyclic_term / 1 from eclipse_language
reexport @=< / 2 from eclipse_language
reexport == / 2 from eclipse_language
reexport \== / 2 from eclipse_language
reexport @< / 2 from eclipse_language
reexport @> / 2 from eclipse_language
reexport @>= / 2 from eclipse_language
reexport functor / 3 from eclipse_language
reexport arg / 3 from eclipse_language
reexport =.. / 2 from eclipse_language
reexport copy_term / 2 from eclipse_language
reexport current_predicate / 1 from eclipse_language
reexport retractall / 1 from eclipse_language
reexport close / 1 from eclipse_language
reexport close / 2 from eclipse_language
reexport nl / 0 from eclipse_language
reexport nl / 1 from eclipse_language
reexport throw / 1 from eclipse_language
reexport write / 1 from eclipse_language
reexport write / 2 from eclipse_language
reexport writeq / 1 from eclipse_language
reexport writeq / 2 from eclipse_language
reexport write_canonical / 1 from eclipse_language
reexport write_canonical / 2 from eclipse_language
reexport \+ / 1 from eclipse_language
reexport once / 1 from eclipse_language
reexport false / 0 from eclipse_language
reexport repeat / 0 from eclipse_language
reexport char_code / 2 from eclipse_language
reexport halt / 0 from eclipse_language
reexport : / 2 from eclipse_language
reexport abolish / 1 from iso_light
reexport asserta / 1 from iso_light
reexport assertz / 1 from iso_light
reexport at_end_of_stream / 0 from iso_light
reexport at_end_of_stream / 1 from iso_light
reexport atom_concat / 3 from iso_light
reexport atom_codes / 2 from iso_light
reexport atom_chars / 2 from iso_light
reexport atom_length / 2 from iso_light
reexport char_conversion / 2 from iso_light
reexport clause / 2 from iso_light
reexport current_char_conversion / 2 from iso_light
reexport current_input / 1 from iso_light
reexport current_op / 3 from iso_light
reexport current_output / 1 from iso_light
reexport flush_output / 0 from iso_light
reexport flush_output / 1 from iso_light
reexport get_byte / 1 from iso_light
reexport get_byte / 2 from iso_light
reexport get_char / 1 from iso_light
reexport get_char / 2 from iso_light
reexport get_code / 1 from iso_light
reexport get_code / 2 from iso_light
reexport halt / 1 from iso_light
reexport number_chars / 2 from iso_light
reexport number_codes / 2 from iso_light
reexport op / 3 from iso_light
reexport peek_byte / 1 from iso_light
reexport peek_byte / 2 from iso_light
reexport peek_char / 1 from iso_light
reexport peek_char / 2 from iso_light
reexport peek_code / 1 from iso_light
reexport peek_code / 2 from iso_light
reexport put_byte / 1 from iso_light
reexport put_byte / 2 from iso_light
reexport put_code / 1 from iso_light
reexport put_code / 2 from iso_light
reexport put_char / 1 from iso_light
reexport put_char / 2 from iso_light
reexport retract / 1 from iso_light
reexport set_input / 1 from iso_light
reexport set_output / 1 from iso_light
reexport set_stream_position / 2 from iso_light
reexport sub_atom / 5 from iso_light
reexport subsumes_term / 2 from iso_light
reexport unify_with_occurs_check / 2 from iso_light
reexport call / 1 from iso_heavy
reexport call / 2 from iso_heavy
reexport call / 3 from iso_heavy
reexport compare / 3 from iso_heavy
reexport sort / 2 from iso_heavy
reexport keysort / 2 from iso_heavy
reexport term_variables / 2 from iso_heavy
reexport findall / 3 from iso_heavy
reexport setof / 3 from iso_heavy
reexport bagof / 3 from iso_heavy
reexport read / 1 from iso_heavy
reexport read / 2 from iso_heavy

Other Exports

export chtab(96, string_quote)
export chtab(34, list_quote)
export syntax_option(dense_output)
export syntax_option(not nl_in_quotes)
export syntax_option(iso_escapes)
export syntax_option(iso_base_prefix)
export syntax_option(iso_restrictions)
export syntax_option(no_string_concatenation)
export syntax_option(eof_is_no_fullstop)
export syntax_option(not syntax_errors_fail)
export syntax_option(plus_is_no_sign)
export syntax_option(doubled_quote_is_quote)
export syntax_option(no_array_subscripts)
export syntax_option(bar_is_no_atom)
export syntax_option(no_attributes)
export syntax_option(no_curly_arguments)
export syntax_option(blanks_after_sign)
export syntax_option(float_needs_point)
export syntax_option(limit_arg_precedence)

Description

Overview

This library provides an implementation of Standard Prolog as defined in ISO/IEC 13211-1 (Information Technology, Programming Languages, Prolog, Part 1, General Core, 1995) and the technical corrigenda ISO/IEC 13211-1 TC1 (2007), TC2 (2012) and TC3 (2017).

It represents the "strict mode" required by ISO 13211-1, paragraph 5.1.e. For a non-strict version, see library(iso).

This is one of three libraries providing different degrees of ISO compatibility:

iso_strict
Aims to be fully ISO compliant, and represents the 'strict mode' required by the standard.
iso
Aims to be fully ISO compliant, but also includes ECLiPSe functionality that does not conflict with the standard.
iso_light
Provides the essence of ISO features without aiming for full conformance (in particular with respect to error handling), and may include ECLiPSe extensions that go beyond what the letter of the standard allows. Also useful for importing individual ISO features into a program that is otherwise written in ECLiPSe dialect.

Usage

The effect of this compatibility library is (with minor exceptions) local to the module where it is loaded. An ISO-program should always be contained in a separate module, starting with a directive like
    :- module(myisomodule, [], iso_strict).
    
Here, the last argument of the module/3 directive indicates the language. It is not advisable to use ":-lib(iso_strict)" or ":-ensure_loaded(library(iso_strict))" within an eclipse_language module, because this would lead to import conflicts between the different versions of built-in predicates.

Alternatively, in order to use ISO-Prolog without having different modules, one can invoke eclipse with a "-L iso_strict" command line option, or set the ECLIPSEDEFFAULTLANGUAGE environment variable to 'iso_strict'. This will launch eclipse with a default module accepting 'iso_strict' language instead of the usual 'eclipse_language'.

Specification of implementation defined features

6.5 Processor characted set
The PCS is the ISO 8859-1 character set. Classification of extended characters: 7f-a0 layout; a1-bf, d7, f7 graphic; c0-d6, d8-f6, f8-ff alphanumeric.
6.6 Collating sequence
The collating sequence is that of the ISO 8859-1 character set
7.1.2.2 Character codes
Each character maps to a corresponding byte
7.1.4.1 Characters
As in the ISO 8859-1 character set
7.2.1 Variable term order
Older variables precede newer variables
7.4.2.4,5 op/3 and char_conversion/2
An operator or character-conversion defined in a directive is effective at runtime, and only in the module in which it occurs
7.4.2.6 initialization/1
Initialization goals are executed in the order in which they occur in the Prolog text
7.4.2.7 include/1
The argument is a file name atom according to ECLiPSe's canonical file name syntax, or a term of the form library(atom)
7.4.2.8 ensure_loaded/1
The argument is a file name atom according to ECLiPSe's canonical file name syntax, or a term of the form library(atom). A file will be loaded on the first occurrence of ensure_loaded/1 in a prolog text, and if the file has been modified since the time it was first loaded.
7.4.2.7 set_prolog_flag/2
Flag setting are effective at runtime and globally (except for a few module-local flags in non-strict mode, see set_flag/2)
7.5.1 Preparing for execution
See the eclipse_language built-ins, menu items and command line options for compiling, loading and module handling, and also the instructions for using library(iso) or library(iso_strict)
7.7.1,3 Execution and Initialization
See the general ECLiPSe facilities, i.e. toplevel, graphical user interface and command line options
7.10.1 Sources and sinks
See open/3,4
7.10.2.6 Text streams
Text streams are very similar to binary streams, no characters are implicitly inserted or removed. The nl/0,1 predicates emit an operating system and device dependent newline sequence.
7.10.2.8,11 Stream positions
File, string, and null streams can be (re)positioned
7.10.2.9 End position of a stream
The end position of a stream is the same as the position that a character appended to the stream would have
7.10.2.11 Stream options
The default eof_action is error
7.10.2.13 Stream properties
File names are atoms according to ECLiPSe's canonical file name syntax.
7.11 Flags
Fixed values: bounded=false, min_integer and max_integer fail, integer_rounding_function=toward_zero, max_arity=unbounded, char_conversion=off. Default values: double_quotes=chars, debug=off. If debug=on, the ECLiPSe tracer is active. In non-strict mode, there is an additional flag max_predicate_arity, which indicates the limit on predicate arity (there is no limit on term arity).
7.12.1 Effect of an error
The implementation defined error term argument is normally the predicate indicator of the culprit goal. For syntax errors, it is a term describing the error location.
8.15.4 call/N
The maximum N is given by the flag max_predicate_arity (255)
8.17.1 set_prolog_flag/2
The admissible flag values are the ones defined by ISO-Prolog
8.17.3,4 halt/0,1
Exits the OS process with the given return code (or 0)
9 Evaluable functors
The 'exceptional values' are realized as follows: 'float_overflow' leads to a floating point infinity result; 'underflow' leads to a floating point denormalized value result; 'zero_divisor' leads to a floating point infinity result in the case of floats, or an evaluation_error(zero_divisor) in the case of integers; 'int_overflow' does not occur and might lead to running out of memory instead.
9.3 Other arithmetic operations
When min/2 or max/2 are used with mixed integer and float arguments, the integer is coerced to float, and the result computed by comparing two floats
9.4 Bitwise arithmetic operations
The bitwise arithmetic operations behave as if operating on an unlimited length two's complement representation

Implementation specific features

None.

Remaining deviations from Standard

  1. The char_conversion flag is always off, meaning that character conversion is not applied to prolog texts or on term input. However, char_conversion/2 and current_char_conversion/2 predicates are operational.

About

See Also

library(multifile), library(iso), library(iso_light)
Generated from iso_strict.eci on 2022-09-03 14:26