file(line, col)=>file(line:col) to follow convention of clang, gcc, dscanner etc

Nick Sabalausky via Digitalmars-d digitalmars-d at puremagic.com
Mon Feb 2 18:54:29 PST 2015


On 01/28/2015 04:52 PM, Timothee Cour via Digitalmars-d wrote:
> See also https://github.com/Hackerpilot/Dscanner/issues/224
> It breaks tooling that expects the main convention.
>

IIRC, file(line,col) is common in the windows world, and I've seen other 
variations, too.

Frankly, I think any editor that's hardcoded to expect any one single 
style is doing it wrong. Accepting either , or : should be trivial for 
any editor, and hell, Programmer's Notepad 2 just uses an 
optionally-customizable regex for error capture. I'd argue that should 
be baseline for any editor.

That said, getting all editors to be that flexible is probably about as 
likely as getting all CLI tools to output the same file/line format, so 
it's probably best (or at least, most realistic) to whip up a little 
streaming IO tool that takes (and optionally detects) one format and 
outputs another. (The Unix Philosophy is really growing on me...even if 
modern Linux seems surprisingly inconsistent about actually using the 
principle...)



More information about the Digitalmars-d mailing list