Re: [dev] [PATCH] sbase: add cut

From: Kurt H Maier <khm-suckless_AT_intma.in>
Date: Wed, 1 Aug 2012 21:58:01 -0400

On Wed, Aug 01, 2012 at 08:33:14PM -0400, Andrew Hills wrote:
> On Wed, Aug 1, 2012 at 6:54 PM, Kurt H Maier <khm-suckless_AT_intma.in> wrote:
> > The question is: since cut can be implemented IN awk, why should it get
> > a separate C binary? Anyone nattering about performance in a shell
> > script is barking up the wrong tree.
>
> Should sed be excluded? What can you do with sed that you can't do in
> awk? For that matter, since Perl can do just about everything, if not
> as quickly or easily, why not support just Perl, and no other tools?
>
> --Andrew Hills
>

relax, genius. I'm not proposing that we drop cut. I'm asking why it
has to be written in C instead of a higher-level language.

sed is not trivial to write in awk. there is nothing you can't do,
obviously, because awk is turing-complete. I realize that you're just
being a shit, but sed is a text editor, and cut is a thing written for
people who couldn't be bothered to learn things. In fact, I'm fairly
certain I could implement cut in sed.

I'm going to ignore your "take the concept to the extreme" straw man
because it isn't interesting. I'm asking for clear cases where binary cut
is obviously superior, and not a bunch of whining because you're used to
it being an individual binary. If you can't deliver, maybe Steven
Blatchford can?
Received on Thu Aug 02 2012 - 03:58:01 CEST

This archive was generated by hypermail 2.3.0 : Thu Aug 02 2012 - 04:00:10 CEST