object
toychrdb
Simple CHR interpreter/debugger based on the refined operational semantics of CHRs.
logtalk_load(toychr(loader))static, context_switching_callsPublic predicates
chr_is/2
Runs a goal against the entity CHR program and returns the resulting constraint store as a conjunction.
staticchr_is(Result,Goal)chr_is(?nonvar,+callable) - zero_or_onechr_trace/0
Enables the CHR interactive trace debugger. Similar to the trace/0 standard predicate.
staticchr_trace - onechr_notrace/0
Disables the CHR interactive trace debugger. Similar to the notrace/0 standard predicate.
staticchr_notrace - onechr_spy/1
Sets a spy point on the activation of constraints matching the given pattern.
staticchr_spy(Pattern)chr_spy(@callable) - onechr_nospy/0
Disables all spy points.
staticchr_nospy - onechr_no_spy/1
Not yet implemented; disables the spy point on constraints matching the given pattern.
staticchr_no_spy(Pattern)chr_no_spy(@callable) - zerochr_option/2
Sets a debugger or compiler option. See the file documentation for the supported options and their values.
staticchr_option(Option,Value)chr_option(+atom,+atom) - zero_or_oneProtected predicates
current_prog/1
Compiled CHR program generated from the entity chr_constraint, handler, and rules terms.
staticcurrent_prog(Program)current_prog(?callable) - zero_or_onechr_option_print_trace/0
True when trace printing is enabled.
dynamicchr_option_print_trace - zero_or_onechr_option_trace_interactive/0
True when interactive tracing is enabled.
dynamicchr_option_trace_interactive - zero_or_onechr_option_optimization_level/1
Current compiler optimization level.
dynamicchr_option_optimization_level(Level)chr_option_optimization_level(?integer) - zero_or_onechr_option_show_stack/0
True when the execution stack is shown while tracing.
dynamicchr_option_show_stack - zero_or_onechr_option_show_store/0
True when the constraint store is shown while tracing.
dynamicchr_option_show_store - zero_or_onechr_option_show_history/0
True when the propagation history is shown while tracing.
dynamicchr_option_show_history - zero_or_onechr_option_show_id/0
True when the current constraint identifier is shown while tracing.
dynamicchr_option_show_id - zero_or_onechr_option_allow_deep_guards/0
True when CHR constraints are allowed in rule guards or if-conditions.
dynamicchr_option_allow_deep_guards - zero_or_onechr_next_state/1
Stack length recorded to detect when the next debugger step is reached.
dynamicchr_next_state(Length)chr_next_state(?integer) - zero_or_onechr_spy_point/1
Asserted clause matching constraints on which a spy point is set.
dynamicchr_spy_point(Constraint)chr_spy_point(@callable) - zero_or_morePrivate predicates
chr_rule_/1
Asserted CHR rule term collected during term-expansion, consumed when compiling the entity program.
dynamicchr_rule_(Rule)chr_rule_(?callable) - zero_or_moreOperators
(none)