clang API Documentation

Enumerations | Functions
clang::driver::types Namespace Reference

Enumerations

enum  ID { TY_INVALID }

Functions

const char * getTypeName (ID Id)
 getTypeName - Return the name of the type for
ID getPreprocessedType (ID Id)
const char * getTypeTempSuffix (ID Id)
bool onlyAssembleType (ID Id)
 onlyAssembleType - Should this type only be assembled.
bool onlyPrecompileType (ID Id)
 onlyPrecompileType - Should this type only be precompiled.
bool canTypeBeUserSpecified (ID Id)
bool appendSuffixForType (ID Id)
bool canLipoType (ID Id)
bool isAcceptedByClang (ID Id)
 isAcceptedByClang - Can clang handle this input type.
bool isOnlyAcceptedByClang (ID Id)
bool isCXX (ID Id)
 isCXX - Is this a "C++" input (C++ and Obj-C++ sources and headers).
bool isObjC (ID Id)
 isObjC - Is this an "ObjC" input (Obj-C and Obj-C++ sources and headers).
ID lookupTypeForExtension (const char *Ext)
ID lookupTypeForTypeSpecifier (const char *Name)
unsigned getNumCompilationPhases (ID Id)
phases::ID getCompilationPhase (ID Id, unsigned N)
ID lookupCXXTypeForCType (ID Id)

Enumeration Type Documentation

Enumerator:
TY_INVALID 

Definition at line 18 of file Types.h.


Function Documentation

bool clang::driver::types::appendSuffixForType ( ID  Id)

appendSuffixForType - When generating outputs of this type, should the suffix be appended (instead of replacing the existing suffix).

Definition at line 63 of file Types.cpp.

References getInfo().

Referenced by clang::driver::Driver::GetNamedOutputPath().

bool clang::driver::types::canLipoType ( ID  Id)

canLipoType - Is this type acceptable as the output of a universal build (currently, just the Nothing, Image, and Object types).

Definition at line 67 of file Types.cpp.

Referenced by clang::driver::Driver::BuildUniversalActions().

bool clang::driver::types::canTypeBeUserSpecified ( ID  Id)

canTypeBeUserSpecified - Can this type be specified on the command line (by the type name); this is used when forwarding commands to gcc.

Definition at line 59 of file Types.cpp.

References getInfo().

Referenced by clang::driver::tools::gcc::Common::ConstructJob(), and lookupTypeForTypeSpecifier().

phases::ID clang::driver::types::getCompilationPhase ( ID  Id,
unsigned  N 
)
unsigned clang::driver::types::getNumCompilationPhases ( ID  Id)

getNumCompilationPhases - Return the complete number of phases to be done for this type.

Definition at line 197 of file Types.cpp.

References getPreprocessedType(), onlyAssembleType(), onlyPrecompileType(), and TY_INVALID.

Referenced by clang::driver::Driver::BuildActions(), and getCompilationPhase().

types::ID clang::driver::types::getPreprocessedType ( ID  Id)

getPreprocessedType - Get the ID of the type for this input when it has been preprocessed, or INVALID if this input is not preprocessed.

Definition at line 43 of file Types.cpp.

References getInfo(), and TypeInfo::PreprocessedType.

Referenced by clang::driver::Driver::BuildActions(), clang::driver::tools::Clang::ConstructJob(), clang::driver::tools::darwin::Compile::ConstructJob(), clang::driver::Driver::ConstructPhaseAction(), clang::driver::Driver::generateCompilationDiagnostics(), getCompilationPhase(), and getNumCompilationPhases().

const char * clang::driver::types::getTypeName ( ID  Id)
const char * clang::driver::types::getTypeTempSuffix ( ID  Id)

getTypeTempSuffix - Return the suffix to use when creating a temp file of this type, or null if unspecified.

Definition at line 47 of file Types.cpp.

References getInfo(), and TypeInfo::TempSuffix.

Referenced by clang::driver::Driver::GetNamedOutputPath().

bool clang::driver::types::isAcceptedByClang ( ID  Id)

isAcceptedByClang - Can clang handle this input type.

Definition at line 73 of file Types.cpp.

Referenced by clang::driver::Driver::ShouldUseClangCompiler().

bool clang::driver::types::isCXX ( ID  Id)
bool clang::driver::types::isObjC ( ID  Id)

isObjC - Is this an "ObjC" input (Obj-C and Obj-C++ sources and headers).

Definition at line 109 of file Types.cpp.

Referenced by addExceptionArgs(), and clang::driver::tools::Clang::ConstructJob().

bool clang::driver::types::isOnlyAcceptedByClang ( ID  Id)

isOnlyAcceptedByClang - Is clang the only compiler that can handle this input type.

Definition at line 96 of file Types.cpp.

Referenced by clang::driver::Driver::ShouldUseClangCompiler().

ID clang::driver::types::lookupCXXTypeForCType ( ID  Id)

lookupCXXTypeForCType - Lookup CXX input type that corresponds to given C type (used for clang++ emulation of g++ behaviour)

Definition at line 239 of file Types.cpp.

Referenced by clang::driver::Driver::BuildInputs().

types::ID clang::driver::types::lookupTypeForExtension ( const char *  Ext)

lookupTypeForExtension - Lookup the type to use for the file extension

  • Ext.

Definition at line 135 of file Types.cpp.

References TY_INVALID.

Referenced by clang::driver::ToolChain::LookupTypeForExtension(), and clang::driver::toolchains::Darwin::LookupTypeForExtension().

types::ID clang::driver::types::lookupTypeForTypeSpecifier ( const char *  Name)

lookupTypeForTypSpecifier - Lookup the type to use for a user specified type name.

Definition at line 182 of file Types.cpp.

References canTypeBeUserSpecified(), getInfo(), numTypes, and TY_INVALID.

Referenced by clang::driver::Driver::BuildInputs().

bool clang::driver::types::onlyAssembleType ( ID  Id)

onlyAssembleType - Should this type only be assembled.

Definition at line 51 of file Types.cpp.

References getInfo().

Referenced by getCompilationPhase(), and getNumCompilationPhases().

bool clang::driver::types::onlyPrecompileType ( ID  Id)

onlyPrecompileType - Should this type only be precompiled.

Definition at line 55 of file Types.cpp.

References getInfo().

Referenced by getCompilationPhase(), and getNumCompilationPhases().