Skip to content
  • Steve Naroff's avatar
    Make Sema's use of the preprocessor explicit (rather than assume · 38d31b47
    Steve Naroff authored
    the prerocessor will be available via ASTContext).
    - Removed the public data member "PP" in ASTContext.
    - Changed ASTContext's contructor to take TargetInfo/IdentifierTable explicitly.
    - Implicitly create an ASTContext in Sema's constructor. This simplifies
    the clients job (and makes ASTContext more private).
    --As a side effect, added a "PrintStats" hook to Sema.
    
    To support this level of encapsulation, ASTContext is always dynamically
    allocated (by Sema). Previously, ASTContext was being allocated on the
    stack. I don't believe this should be a performance issue (since ASTContext
    is fairly course grain and tied to the lifetime of Sema currently).
    
    llvm-svn: 39345
    38d31b47
Loading