clang API Documentation

Classes | Public Member Functions
clang::PPConditionalDirectiveRecord Class Reference

Records preprocessor conditional directive regions and allows querying in which region source locations belong to. More...

#include <PPConditionalDirectiveRecord.h>

Inheritance diagram for clang::PPConditionalDirectiveRecord:
Inheritance graph
[legend]
Collaboration diagram for clang::PPConditionalDirectiveRecord:
Collaboration graph
[legend]

List of all members.

Classes

class  CondDirectiveLoc

Public Member Functions

 PPConditionalDirectiveRecord (SourceManager &SM)
 Construct a new preprocessing record.
size_t getTotalMemory () const
SourceManagergetSourceManager () const
bool rangeIntersectsConditionalDirective (SourceRange Range) const
 Returns true if the given range intersects with a conditional directive. if a #if/#endif block is fully contained within the range, this function will return false.
bool areInDifferentConditionalDirectiveRegion (SourceLocation LHS, SourceLocation RHS) const
 Returns true if the given locations are in different regions, separated by conditional directive blocks.
SourceLocation findConditionalDirectiveRegionLoc (SourceLocation Loc) const

Detailed Description

Records preprocessor conditional directive regions and allows querying in which region source locations belong to.

Definition at line 26 of file PPConditionalDirectiveRecord.h.


Constructor & Destructor Documentation

Construct a new preprocessing record.

Definition at line 19 of file PPConditionalDirectiveRecord.cpp.


Member Function Documentation

Returns true if the given locations are in different regions, separated by conditional directive blocks.

Definition at line 80 of file PPConditionalDirectiveRecord.h.

References findConditionalDirectiveRegionLoc().

Referenced by clang::edit::Commit::insertFromRange().

Definition at line 71 of file PPConditionalDirectiveRecord.h.

Definition at line 120 of file PPConditionalDirectiveRecord.cpp.

Returns true if the given range intersects with a conditional directive. if a #if/#endif block is fully contained within the range, this function will return false.

Definition at line 24 of file PPConditionalDirectiveRecord.cpp.

References clang::SourceRange::getBegin(), clang::SourceRange::getEnd(), clang::SourceManager::isBeforeInTranslationUnit(), and clang::SourceRange::isInvalid().


The documentation for this class was generated from the following files: