aaron.ballman added a comment.

In https://reviews.llvm.org/D51192#1226257, @steveire wrote:

> How? This is 'private' code. I don't think it's worth changing that or 
> creating a test with a huge amount of infrastructure in order to test this 
> indirectly.


This is changing the observable behavior of the tool, so it should have tests 
unless they're impossible to write.

> Am I missing something?

I'd probably pipe the diagnostic output to a temporary file that gets 
FileChecked with strict whitespace to see if the underlines from the diagnostic 
match the expected locations. We do this in a few Clang tests, like 
SemaCXX\struct-class-redecl.cpp or Misc\wrong-encoding.c.


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D51192



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to