projects
/
collection4.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
src/graph_instance.[ch]: Implement "inst_compare".
[collection4.git]
/
src
/
graph_instance.c
diff --git
a/src/graph_instance.c
b/src/graph_instance.c
index
cce7265
..
93fc3c5
100644
(file)
--- a/
src/graph_instance.c
+++ b/
src/graph_instance.c
@@
-433,6
+433,12
@@
int inst_get_params (graph_config_t *cfg, graph_instance_t *inst, /* {{{ */
return (0);
} /* }}} int inst_get_params */
return (0);
} /* }}} int inst_get_params */
+int inst_compare (const graph_instance_t *i0, /* {{{ */
+ const graph_instance_t *i1)
+{
+ return (ident_compare (i0->select, i1->select));
+} /* }}} int inst_compare */
+
int inst_compare_ident (graph_instance_t *inst, /* {{{ */
const graph_ident_t *ident)
{
int inst_compare_ident (graph_instance_t *inst, /* {{{ */
const graph_ident_t *ident)
{
@@
-445,8
+451,10
@@
int inst_compare_ident (graph_instance_t *inst, /* {{{ */
_Bool inst_ident_matches (graph_instance_t *inst, /* {{{ */
const graph_ident_t *ident)
{
_Bool inst_ident_matches (graph_instance_t *inst, /* {{{ */
const graph_ident_t *ident)
{
+#if C4_DEBUG
if ((inst == NULL) || (ident == NULL))
return (0);
if ((inst == NULL) || (ident == NULL))
return (0);
+#endif
return (ident_matches (inst->select, ident));
} /* }}} _Bool inst_ident_matches */
return (ident_matches (inst->select, ident));
} /* }}} _Bool inst_ident_matches */