Skip to content

Commit

Permalink
Merge branch 'cmd/print--unique'
Browse files Browse the repository at this point in the history
* cmd/print--unique:
  doc, change help text for -u|--unique
  minor, use ctl_caev_equal_p() as predicate for uniqueness in printers
  • Loading branch information
hroptatyr committed Feb 12, 2015
2 parents 1796136 + 7987714 commit 3452c6a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/cattle.c
Original file line number Diff line number Diff line change
Expand Up @@ -1365,7 +1365,7 @@ ctl_print_raw(struct ctl_ctx_s ctx[static 1U], bool uniqp, bool revp)

if (uniqp) {
if (echs_instant_eq_p(prev_t, t) &&
ctl_caev_eq_p(this, prev)) {
ctl_caev_equal_p(this, prev)) {
/* completely identical */
continue;
}
Expand Down Expand Up @@ -1401,7 +1401,7 @@ ctl_print_sum(struct ctl_ctx_s ctx[static 1U], bool uniqp, bool revp)

if (uniqp) {
if (echs_instant_eq_p(prev_t, t) &&
ctl_caev_eq_p(this, prev)) {
ctl_caev_equal_p(this, prev)) {
/* completely identical */
continue;
}
Expand Down Expand Up @@ -1446,7 +1446,7 @@ ctl_print_kv(struct ctl_ctx_s ctx[static 1U], bool uniqp)
ctl_caev_t this_c = ctl_kvv_get_caev(this);

if (echs_instant_eq_p(prev_t, t) &&
ctl_caev_eq_p(this_c, prev_c)) {
ctl_caev_equal_p(this_c, prev_c)) {
continue;
}
/* store actor representation for the next round */
Expand Down
4 changes: 2 additions & 2 deletions src/cattle.yuck
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ Print resulting actors of caev echse messages.
-S, --summary Roll all CA events into one.
-R, --reverse Invert CA events, implies -r|--raw.
-r, --raw Print raw actors.
-u, --unique Assume that only one CA event will occur at any
one date/time.
-u, --unique Consider two CA events that do the same
equivalent and print only the first one.


Usage: cattle exp TIME-SERIES-FILE [CAEV-FILE]...
Expand Down

0 comments on commit 3452c6a

Please sign in to comment.