clang  6.0.0svn
Public Types | Public Member Functions | Static Public Member Functions | List of all members
clang::CodeGen::RequiredArgs Class Reference

A class for recording the number of arguments that a function signature requires. More...

#include "clang/CodeGen/CGFunctionInfo.h"

Public Types

enum  All_t { All }
 

Public Member Functions

 RequiredArgs (All_t _)
 
 RequiredArgs (unsigned n)
 
bool allowsOptionalArgs () const
 
unsigned getNumRequiredArgs () const
 
unsigned getOpaqueData () const
 

Static Public Member Functions

static RequiredArgs forPrototypePlus (const FunctionProtoType *prototype, unsigned additional, const FunctionDecl *FD)
 Compute the arguments required by the given formal prototype, given that there may be some additional, non-formal arguments in play. More...
 
static RequiredArgs forPrototype (const FunctionProtoType *prototype, const FunctionDecl *FD)
 
static RequiredArgs forPrototype (CanQual< FunctionProtoType > prototype, const FunctionDecl *FD)
 
static RequiredArgs forPrototypePlus (CanQual< FunctionProtoType > prototype, unsigned additional, const FunctionDecl *FD)
 
static RequiredArgs getFromOpaqueData (unsigned value)
 

Detailed Description

A class for recording the number of arguments that a function signature requires.

Definition at line 381 of file CGFunctionInfo.h.

Member Enumeration Documentation

◆ All_t

Enumerator
All 

Definition at line 386 of file CGFunctionInfo.h.

Constructor & Destructor Documentation

◆ RequiredArgs() [1/2]

clang::CodeGen::RequiredArgs::RequiredArgs ( All_t  _)
inline

Definition at line 388 of file CGFunctionInfo.h.

◆ RequiredArgs() [2/2]

clang::CodeGen::RequiredArgs::RequiredArgs ( unsigned  n)
inlineexplicit

Definition at line 389 of file CGFunctionInfo.h.

Member Function Documentation

◆ allowsOptionalArgs()

bool clang::CodeGen::RequiredArgs::allowsOptionalArgs ( ) const
inline

◆ forPrototype() [1/2]

static RequiredArgs clang::CodeGen::RequiredArgs::forPrototype ( const FunctionProtoType prototype,
const FunctionDecl FD 
)
inlinestatic

Definition at line 410 of file CGFunctionInfo.h.

◆ forPrototype() [2/2]

static RequiredArgs clang::CodeGen::RequiredArgs::forPrototype ( CanQual< FunctionProtoType prototype,
const FunctionDecl FD 
)
inlinestatic

Definition at line 415 of file CGFunctionInfo.h.

References clang::CanQual< T >::getTypePtr().

◆ forPrototypePlus() [1/2]

static RequiredArgs clang::CodeGen::RequiredArgs::forPrototypePlus ( const FunctionProtoType prototype,
unsigned  additional,
const FunctionDecl FD 
)
inlinestatic

Compute the arguments required by the given formal prototype, given that there may be some additional, non-formal arguments in play.

If FD is not null, this will consider pass_object_size params in FD.

Definition at line 398 of file CGFunctionInfo.h.

References clang::All, clang::FunctionProtoType::getNumParams(), clang::FunctionProtoType::isVariadic(), and clang::FunctionDecl::parameters().

Referenced by clang::CodeGen::CodeGenTypes::arrangeBlockFunctionDeclaration(), clang::CodeGen::CodeGenTypes::arrangeCXXConstructorCall(), arrangeLLVMFunctionInfo(), commonEmitCXXMemberOrOperatorCall(), and clang::CodeGen::CodeGenFunction::EmitCallAndReturnForThunk().

◆ forPrototypePlus() [2/2]

static RequiredArgs clang::CodeGen::RequiredArgs::forPrototypePlus ( CanQual< FunctionProtoType prototype,
unsigned  additional,
const FunctionDecl FD 
)
inlinestatic

Definition at line 420 of file CGFunctionInfo.h.

References clang::CanQual< T >::getTypePtr().

◆ getFromOpaqueData()

static RequiredArgs clang::CodeGen::RequiredArgs::getFromOpaqueData ( unsigned  value)
inlinestatic

Definition at line 433 of file CGFunctionInfo.h.

References clang::All.

◆ getNumRequiredArgs()

unsigned clang::CodeGen::RequiredArgs::getNumRequiredArgs ( ) const
inline

Definition at line 427 of file CGFunctionInfo.h.

◆ getOpaqueData()

unsigned clang::CodeGen::RequiredArgs::getOpaqueData ( ) const
inline

Definition at line 432 of file CGFunctionInfo.h.

Referenced by clang::CodeGen::CGFunctionInfo::Profile().


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