develooper Front page | perl.perl5.porters | Postings from May 2014

Re: RFC: Making -B and -T work better on 8-bit encodings

Thread Previous | Thread Next
From:
Ævar Arnfjörð Bjarmason
Date:
May 6, 2014 20:04
Subject:
Re: RFC: Making -B and -T work better on 8-bit encodings
Message ID:
CACBZZX7uLSvnTqJ4-qpYGPgBG9QU_J24qgeT+DZpktPYp22YQg@mail.gmail.com
On Fri, May 2, 2014 at 10:28 PM, Karl Williamson
<public@khwilliamson.com> wrote:
> The -B and -T file test operators don't really work well for non-ASCII text
> files, except perhaps under 'use locale'

How does the old functionality and the proposed new functionality
compare to the binary detection done by file(1), grep(1) and a other
standard *nix utilities that also do binary detection? Perhaps there's
others that do that I'm forgetting, but this seems like a problem
that's been solved before by multiple independent implementations.

I've never used these operators myself, but I can imagine that one of
the common usecases for them is as a heuristic to find files to pass
to those other commands, what are they commonly used for?

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About