#8 ErrorList: option to preserve order of errors

open
nobody
None
5
2006-09-07
2006-09-07
Alan Ezust
No

For C++ it is very annoying to see the errors all
sorted in the errorlist. Much meaning is lost, because
the errors/warnings are often related to each other and
span multiple lines.

Discussion

  • ErrorList currently groups errors under the file in which they are reported. Which means, if I have output lines specifying errors, in the following order:
    File Line
    c.c 20
    b.c 30
    c.c 10
    Then both errors from 'c.c' will be grouped under the same parent in ErrorList. In order to maintain the original order, ErrorList needs to either flatten the tree so that each error node specifies also the file, or, alternatively, have multiple nodes at the top level (file level) referring to the same file. Both solutions do not seem to be very convenient - e.g. for the above example there will be 2 nodes for 'c.c' with 'b.c' between them.

    I can implement this, but I think it's not the right way to handle the real issue - which is grouping several source code links under a single error (e.g. syntax error in file:line, including from file:line, included from file:line), and then at some point we'll want to handle it correctly and this feature of preserve error order will be neglected. However, handling this issue correctly also needs to take part in the Console plugin, which I don't think is currently ready to group such messages, if ErrorList had the API for that.

     
  • Alan Ezust
    Alan Ezust
    2010-01-18

    I'm thinking just an option to "not group by file" but instead just preserve the order.

     
  • Alan Ezust
    Alan Ezust
    2010-01-18

    And perhaps it can be a mode option, since people might only want it in C++, for example.

     
  • Alan Ezust
    Alan Ezust
    2012-01-29

    From 2780273, it seems to be an issue with Ruby also.