Thanks for reviewing.
as you wrote, diff content may not be utf8 at all. and we don't know that the
user's terminal watns is utf8.
I think your trying utf8 decode and fall back approach is better than my patch,
and do work well.
is using "$@" for catching error like the patch below?
According to
On Thu, Feb 13, 2014 at 01:17:54AM +, brian m. carlson wrote:
> On Wed, Feb 12, 2014 at 06:27:40PM -0500, Jeff King wrote:
> > On Wed, Feb 12, 2014 at 11:10:49PM +, Thomas Adam wrote:
> >
> > > On 12 February 2014 20:59, Jeff King wrote:
> > > > +sub decode {
> > > > + my $orig = s
On Wed, Feb 12, 2014 at 06:27:40PM -0500, Jeff King wrote:
> On Wed, Feb 12, 2014 at 11:10:49PM +, Thomas Adam wrote:
>
> > On 12 February 2014 20:59, Jeff King wrote:
> > > +sub decode {
> > > + my $orig = shift;
> > > + my $decoded = eval { decode_utf8($orig, Encode::FB_CROAK) }
On Wed, Feb 12, 2014 at 11:10:49PM +, Thomas Adam wrote:
> On 12 February 2014 20:59, Jeff King wrote:
> > +sub decode {
> > + my $orig = shift;
> > + my $decoded = eval { decode_utf8($orig, Encode::FB_CROAK) };
> > + return defined $decoded ?
>
> I'd still advocate checkin
On 12 February 2014 20:59, Jeff King wrote:
> +sub decode {
> + my $orig = shift;
> + my $decoded = eval { decode_utf8($orig, Encode::FB_CROAK) };
> + return defined $decoded ?
I'd still advocate checking $@ here, rather than the defined $decoded check.
> + ($decod
On Tue, Feb 11, 2014 at 06:09:10PM +0900, Yoshihiro Sugi wrote:
> diff-highlight split each hunks and compare them as byte sequences.
> it causes problems when diff hunks include multibyte characters.
> This change enable to work on such cases by decoding inputs and encoding
> output as utf8 stri
Yoshihiro Sugi writes:
> Signed-off-by: Yoshihiro Sugi
>
> diff-highlight split each hunks and compare them as byte sequences.
> it causes problems when diff hunks include multibyte characters.
> This change enable to work on such cases by decoding inputs and encoding
> output as utf8 string.
>
Signed-off-by: Yoshihiro Sugi
diff-highlight split each hunks and compare them as byte sequences.
it causes problems when diff hunks include multibyte characters.
This change enable to work on such cases by decoding inputs and encoding output
as utf8 string.
---
contrib/diff-highlight/diff-high
8 matches
Mail list logo