Commit Graph

3 Commits

Author SHA1 Message Date
Chris Lattner dc5c055fd1 Reimplement SourceLocation. Instead of having a
fileid/offset pair, it now contains a bit discriminating between
mapped locations and file locations.  This separates the tables for
macros and files in SourceManager, and allows better separation of
concepts in the rest of the compiler.  This allows us to have *many*
macro instantiations before running out of 'addressing space'.

This is also more efficient, because testing whether something is a
macro expansion is now a bit test instead of a table lookup (which
also used to require having a srcmgr around, now it doesn't).

This is fully functional, but there are several refinements and
optimizations left.

llvm-svn: 40103
2007-07-20 16:37:10 +00:00
Chris Lattner 23b7eb677d Finally bite the bullet and make the major change: split the clang namespace
out of the llvm namespace.  This makes the clang namespace be a sibling of
llvm instead of being a child.

The good thing about this is that it makes many things unambiguous.  The
bad things is that many things in the llvm namespace (notably data structures
like smallvector) now require an llvm:: qualifier.  IMO, libsystem and libsupport
should be split out of llvm into their own namespace in the future, which will fix
this issue.

llvm-svn: 39659
2007-06-15 23:05:46 +00:00
Bill Wendling 478b88638f Submitted by: Bill Wendling
Reviewed by: Chris Lattner

- Created a base class (TextDiagnostics) for all text diagnostic classes.
  Moved the "IgnoreDiagnostic" method up there, and created a method that
  will format the diagnostic string, replacing %# with the appropriate
  string. This is in preparation for adding a text diagnostic checker.

llvm-svn: 39650
2007-06-13 17:45:37 +00:00