Re: [PATCH 2/2] chainlint: reduce annotation noise-factor

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 29, 2024 at 12:03:37PM +0200, Patrick Steinhardt wrote:

> Okay, now the "ERR" prefix becomes a bit more important because we drop
> the other punctuation. I'm still not much of a fan of it, though. Makes
> me wonder whether we want to take a clue from how compilers nowadays
> format this, e.g. by using "pointers".
> 
> So this:
> 
>     2 (
>     3 	foo |
>     4 	bar |
>     5 	baz &&
>     6 
>     7 	fish |
>     8 	cow ?!AMP?!
>     9 
>     10 	sunder
>     11 )
> 
> Would become this:
> 
>     t/chainlint/pipe.actual:8: error: expected ampersands (&&)
>     7 	fish |
>     8 	cow 
>             ^
>     9
> 
> While this would be neat, I guess it would also be way more work than
> the current series you have posted. And whether that work is ultimately
> really worth it may be another question. Probably not.

I think that output is quite readable. One bonus is that it follows the
usual "quickfix" format, so there's editor support for jumping to the
problematic spot.

It probably is more verbose if you have multiple errors right next to
each other (since now we just show the annotated source text). But that
is going to be relatively rare compared to single mistakes, I'd think.

-Peff




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux