summaryrefslogtreecommitdiffstats
path: root/clang/lib/Driver/TextDiagnosticBuffer.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Rename lib/Driver (etc) to lib/Frontend in prep for the *actual*Daniel Dunbar2009-03-021-39/+0
| | | | | | driver taking lib/Driver. llvm-svn: 65811
* Handle fatal errors.Ben Laurie2009-02-171-0/+1
| | | | llvm-svn: 64770
* eliminate FullSourceLoc::getLocation() now that FullSourceLocChris Lattner2009-01-161-3/+3
| | | | | | *is* the location. This eliminates some weird X.getLocation().getLocation()'s. llvm-svn: 62376
* rewrite FormatDiagnostic to be less gross and a lot more efficient.Chris Lattner2008-11-191-6/+7
| | | | | | | This also makes it illegal to have bare '%'s in diagnostics. If you want a % in a diagnostic, use %%. llvm-svn: 59596
* This reworks some of the Diagnostic interfaces a bit to change how diagnosticsChris Lattner2008-11-181-17/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | are formed. In particular, a diagnostic with all its strings and ranges is now packaged up and sent to DiagnosticClients as a DiagnosticInfo instead of as a ton of random stuff. This has the benefit of simplifying the interface, making it more extensible, and allowing us to do more checking for things like access past the end of the various arrays passed in. In addition to introducing DiagnosticInfo, this also substantially changes how Diagnostic::Report works. Instead of being passed in all of the info required to issue a diagnostic, Report now takes only the required info (a location and ID) and returns a fresh DiagnosticInfo *by value*. The caller is then free to stuff strings and ranges into the DiagnosticInfo with the << operator. When the dtor runs on the DiagnosticInfo object (which should happen at the end of the statement), the diagnostic is actually emitted with all of the accumulated information. This is a somewhat tricky dance, but it means that the accumulated DiagnosticInfo is allowed to keep pointers to other expression temporaries without those pointers getting invalidated. This is just the minimal change to get this stuff working, but this will allow us to eliminate the zillions of variant "Diag" methods scattered throughout (e.g.) sema. For example, instead of calling: Diag(BuiltinLoc, diag::err_overload_no_match, typeNames, SourceRange(BuiltinLoc, RParenLoc)); We will soon be able to just do: Diag(BuiltinLoc, diag::err_overload_no_match) << typeNames << SourceRange(BuiltinLoc, RParenLoc)); This scales better to support arbitrary types being passed in (not just strings) in a type-safe way. Go operator overloading?! llvm-svn: 59502
* Change the diagnostics interface to take an array of pointers to Chris Lattner2008-11-181-1/+1
| | | | | | | | strings instead of array of strings. This reduces string copying in some not-very-important cases, but paves the way for future improvements. llvm-svn: 59494
* First non-embarrassing cut at checking for ambiguous derived-to-base Douglas Gregor2008-10-241-1/+2
| | | | | | | | | | conversions. Added PerformImplicitConversion, which follows an implicit conversion sequence computed by TryCopyInitialization and actually performs the implicit conversions, including the extra check for ambiguity mentioned above. llvm-svn: 58071
* Add support for expected-note to Clang's -verify optionDouglas Gregor2008-09-111-0/+5
| | | | llvm-svn: 56089
* More #include cleaningDaniel Dunbar2008-08-111-1/+0
| | | | | | | | | | | - Kill unnecessary #includes in .cpp files. This is an automatic sweep so some things removed are actually used, but happen to be included by a previous header. I tried to get rid of the obvious examples and this was the easiest way to trim the #includes in one fell swoop. - We now return to regularly scheduled development. llvm-svn: 54632
* add a libDriver, for now only move the text diangostics stuff from Driver to ↵Nico Weber2008-08-051-0/+41
there llvm-svn: 54383
OpenPOWER on IntegriCloud