indenting; warning; exceptions; small fixes

This commit is contained in:
Vítor Santos Costa
2016-03-29 02:02:43 +01:00
parent 6bc4acec15
commit f3e8b8b3da
51 changed files with 2220 additions and 2221 deletions

View File

@@ -2,9 +2,8 @@
:- module(clpbn_gviz,
[clpbn2gviz/4]).
clpbn2gviz(Stream, Name, Network, Output) :-
format(Stream, 'digraph ~w {
graph [ rankdir="LR" ];~n',[Name]),
clpbn2gviz(Stream, Name, Network, Node, Edge, Output) :-
format(Stream, 'digraph ~w { ~n graph [ rankdir="LR" ];~n',[Name]),
output_vars(Stream, Network),
info_ouput(Stream, Output),
format(Stream, '}~n',[]).

View File

@@ -204,7 +204,8 @@ in_table(K, V) :-
store_in_table(K, V) :-
b_getval(clpbn_tables, Tab),
b_hash_insert(Tab, K, V).
b_hash_insert(Tab, K, V, NewTab),
( Tab == NewTab -> true ; b_setval(clpbn_tables, NewTab)).
clpbn_tabled_clause(M:Head, Body) :- !,
clpbn_tabled_clause(Head, M, Body).