CppParser
Loading...
Searching...
No Matches
CppHashIf Struct Reference

Represents all variants of #if preprocessors. More...

#include <cppast.h>

Inheritance diagram for CppHashIf:
Inheritance graph
Collaboration diagram for CppHashIf:
Collaboration graph

Public Types

enum  CondType {
  kIf , kIfDef , kIfNDef , kElse ,
  kElIf , kEndIf
}
 

Public Member Functions

 CppHashIf (CondType condType, std::string cond=std::string())
 
void accept (CppVisitorBase *v) override
 
- Public Member Functions inherited from CppObj
 CppObj (CppObjType type, CppAccessType accessType)
 
CppCompoundowner ()
 
void owner (CppCompound *o)
 
virtual void accept (CppVisitorBase *v)=0
 
virtual ~CppObj ()
 

Public Attributes

CondType condType_
 
std::string cond_
 
- Public Attributes inherited from CppObj
CppObjType objType_
 
CppAccessType accessType_
 All objects do not need this. More...
 

Static Public Attributes

static constexpr CppObjType kObjectType = CppObjType::kHashIf
 

Detailed Description

Represents all variants of #if preprocessors.

It includes #if, #ifdef, #ifndef. It also includes #else, #elif, and #endif.

Definition at line 275 of file cppast.h.

Member Enumeration Documentation

◆ CondType

Enumerator
kIf 
kIfDef 
kIfNDef 
kElse 
kElIf 
kEndIf 

Definition at line 279 of file cppast.h.

Constructor & Destructor Documentation

◆ CppHashIf()

CppHashIf::CppHashIf ( CondType  condType,
std::string  cond = std::string() 
)
inline

Definition at line 292 of file cppast.h.

Member Function Documentation

◆ accept()

void CppHashIf::accept ( CppVisitorBase v)
inlineoverridevirtual

Implements CppObj.

Definition at line 299 of file cppast.h.

Here is the call graph for this function:

Member Data Documentation

◆ cond_

std::string CppHashIf::cond_

Definition at line 290 of file cppast.h.

◆ condType_

CondType CppHashIf::condType_

Definition at line 289 of file cppast.h.

◆ kObjectType

constexpr CppObjType CppHashIf::kObjectType = CppObjType::kHashIf
staticconstexpr

Definition at line 277 of file cppast.h.


The documentation for this struct was generated from the following file: