MCPcopy Index your code
hub / github.com/coreutils/coreutils / prfields

Function prfields

src/join.c:599–614  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

597/* Output all the fields in line, other than the join field. */
598
599static void
600prfields (struct line const *line, idx_t join_field, idx_t autocount)
601{
602 idx_t nfields = autoformat ? autocount : line->nfields;
603
604 for (idx_t i = 0; i < join_field && i < nfields; ++i)
605 {
606 fwrite (output_separator, 1, output_seplen, stdout);
607 prfield (i, line);
608 }
609 for (idx_t i = join_field + 1; i < nfields; ++i)
610 {
611 fwrite (output_separator, 1, output_seplen, stdout);
612 prfield (i, line);
613 }
614}
615
616/* Print the join of LINE1 and LINE2. */
617

Callers 1

prjoinFunction · 0.85

Calls 1

prfieldFunction · 0.85

Tested by

no test coverage detected