Puma Reference Manual Puma::CSemExpr Class Reference



Puma::CSemExpr Class Reference

#include <CSemExpr.h>

Classes

struct  SubObj

Public Member Functions

 CSemExpr (ErrorSink &, CStructure *scope)
CTypeInforesolveExpr (CTree *expr, CTree *base=(CTree *) 0)
void resolveInit (CObjectInfo *, CTree *, CTree *, bool=false)
CTypeInforesolve (CTree *, CTree *)
CTypeInforesolve (CT_SimpleName *, CTree *)
CTypeInforesolve (CT_String *, CTree *)
CTypeInforesolve (CT_WideString *, CTree *)
CTypeInforesolve (CT_CmpdLiteral *, CTree *)
CTypeInforesolve (CT_Bool *, CTree *)
CTypeInforesolve (CT_Character *, CTree *)
CTypeInforesolve (CT_WideCharacter *, CTree *)
CTypeInforesolve (CT_Integer *, CTree *)
CTypeInforesolve (CT_Float *, CTree *)
CTypeInforesolve (CT_BracedExpr *, CTree *)
CTypeInforesolve (CT_BinaryExpr *, CTree *)
CTypeInforesolve (CT_UnaryExpr *, CTree *)
CTypeInforesolve (CT_AddrExpr *, CTree *)
CTypeInforesolve (CT_DerefExpr *, CTree *)
CTypeInforesolve (CT_PostfixExpr *, CTree *)
CTypeInforesolve (CT_IndexExpr *, CTree *)
CTypeInforesolve (CT_SizeofExpr *, CTree *)
CTypeInforesolve (CT_AlignofExpr *, CTree *)
CTypeInforesolve (CT_OffsetofExpr *, CTree *)
CTypeInforesolve (CT_IfThenExpr *, CTree *)
CTypeInforesolve (CT_CastExpr *, CTree *)
CTypeInforesolve (CT_CallExpr *, CTree *)
CTypeInforesolve (CT_MembPtrExpr *, CTree *)
CTypeInfobinary_rel (CT_BinaryExpr *)
CTypeInfobinary_ass (CT_BinaryExpr *)
CTypeInfobinary_log (CT_BinaryExpr *)
CTypeInfobinary_and (CT_BinaryExpr *)
CTypeInfobinary_equ (CT_BinaryExpr *)
CTypeInfobinary_mul (CT_BinaryExpr *)
CTypeInfobinary_add (CT_BinaryExpr *)
CTypeInfobinary_shift (CT_BinaryExpr *)
CTypeInfobinary_comma (CT_BinaryExpr *)
CTypeInfoapply_binary_op (CTree *, int)
CTypeInfoapplyImplicitConv (CTree *expr, CTree *base, CTypeInfo *type)
void overflow (CTree *, int, bool &) const
int scan_character (CTree *, LONG_LONG &) const
LONG_LONG next_character (const char *&, bool &) const
CTypeInfocond_expr_type (CT_IfThenExpr *node, CTypeInfo *t1, CTree *op1, CTypeInfo *t2, CTree *op2, CTypeInfo *t3, CTree *op3)

Static Public Member Functions

static bool isConstExpr (CTree *, bool=false)
static bool isConstIntExpr (CTree *)
static bool isConstantMembPtr (CTree *node)
static bool isLvalue (CTree *)
static void passOnConstant (CTree *node, CTree *base, CTypeInfo *t1)
static CTypeInfocast_to (CTypeInfo *, CTree *, CTree *, bool=true)
static CTypeInfopromote (CTree *, CTree *)
static CObjectInfofindObject (CTree *, bool const_expr=false)
static bool isPtrToObj (CTypeInfo *, unsigned long=0)
static bool isModifiable (CTypeInfo *, unsigned long=0)
static bool compatible (CTypeInfo *, CTypeInfo *, CConstant *value=0)
static bool compatibleBase (CTypeInfo *, CTypeInfo *, CConstant *value=0)

Protected Types

enum  SemObjType {
  CLASS,
  UNION,
  ENUM,
  TYPEDEF,
  FCT,
  ATTRIB,
  ARG,
  TAG,
  NON_TAG,
  ANY
}

Protected Member Functions

void resolveInit (CObjectInfo *, CTree *, CTree *, bool, Stack< SubObj > &)
void singleExprInit (CTree *, CTree *, CTypeInfo *, bool)
void findFirst (CTree *, CTypeInfo *&, CObjectInfo *&, CObjectInfo *&, CObjectInfo *, Stack< SubObj > &, bool) const
void findNext (CTree *, CTypeInfo *&, CObjectInfo *&, CObjectInfo *&, CObjectInfo *, Stack< SubObj > &, bool) const
void pushSubObj (CTypeInfo *&, CObjectInfo *&, Stack< SubObj > &) const
void popSubObj (CTypeInfo *&, CObjectInfo *&, CObjectInfo *&, Stack< SubObj > &) const
CObjectInfonextMember (CStructure *, CObjectInfo *) const
CObjectInfolookup (CT_SimpleName *, SemObjType, bool=false) const
CObjectInfolookup (const char *, CStructure *, SemObjType, bool, unsigned long int) const
CObjectInfoType (const char *, CStructure *, SemObjType, unsigned long int) const
CObjectInfoAttribute (const char *, CStructure *, unsigned long int) const
CObjectInfoFunction (const char *, CStructure *, unsigned long int) const
bool known_here (CObjectInfo *, unsigned long int) const

Protected Attributes

ErrorSinkerr
CStructurecurrent_scope
int conv_to_ptr

Member Enumeration Documentation

Enumerator:
CLASS 
UNION 
ENUM 
TYPEDEF 
FCT 
ATTRIB 
ARG 
TAG 
NON_TAG 
ANY 

Constructor & Destructor Documentation

Puma::CSemExpr::CSemExpr ( ErrorSink e,
CStructure scope 
)
inline

Member Function Documentation

CTypeInfo* Puma::CSemExpr::apply_binary_op ( CTree ,
int   
)
CTypeInfo* Puma::CSemExpr::applyImplicitConv ( CTree expr,
CTree base,
CTypeInfo type 
)
CObjectInfo* Puma::CSemExpr::Attribute ( const char *  ,
CStructure ,
unsigned long  int 
) const
protected
CTypeInfo* Puma::CSemExpr::binary_add ( CT_BinaryExpr )
CTypeInfo* Puma::CSemExpr::binary_and ( CT_BinaryExpr )
CTypeInfo* Puma::CSemExpr::binary_ass ( CT_BinaryExpr )
CTypeInfo* Puma::CSemExpr::binary_comma ( CT_BinaryExpr )
CTypeInfo* Puma::CSemExpr::binary_equ ( CT_BinaryExpr )
CTypeInfo* Puma::CSemExpr::binary_log ( CT_BinaryExpr )
CTypeInfo* Puma::CSemExpr::binary_mul ( CT_BinaryExpr )
CTypeInfo* Puma::CSemExpr::binary_rel ( CT_BinaryExpr )
CTypeInfo* Puma::CSemExpr::binary_shift ( CT_BinaryExpr )
static CTypeInfo* Puma::CSemExpr::cast_to ( CTypeInfo ,
CTree ,
CTree ,
bool  = true 
)
static
static bool Puma::CSemExpr::compatible ( CTypeInfo ,
CTypeInfo ,
CConstant value = 0 
)
static
bool Puma::CSemExpr::compatibleBase ( CTypeInfo t1,
CTypeInfo t2,
CConstant value = 0 
)
inlinestatic
CTypeInfo* Puma::CSemExpr::cond_expr_type ( CT_IfThenExpr node,
CTypeInfo t1,
CTree op1,
CTypeInfo t2,
CTree op2,
CTypeInfo t3,
CTree op3 
)
void Puma::CSemExpr::findFirst ( CTree ,
CTypeInfo *&  ,
CObjectInfo *&  ,
CObjectInfo *&  ,
CObjectInfo ,
Stack< SubObj > &  ,
bool   
) const
protected
void Puma::CSemExpr::findNext ( CTree ,
CTypeInfo *&  ,
CObjectInfo *&  ,
CObjectInfo *&  ,
CObjectInfo ,
Stack< SubObj > &  ,
bool   
) const
protected
static CObjectInfo* Puma::CSemExpr::findObject ( CTree ,
bool  const_expr = false 
)
static
CObjectInfo* Puma::CSemExpr::Function ( const char *  ,
CStructure ,
unsigned long  int 
) const
protected
static bool Puma::CSemExpr::isConstantMembPtr ( CTree node)
static
static bool Puma::CSemExpr::isConstExpr ( CTree ,
bool  = false 
)
static
static bool Puma::CSemExpr::isConstIntExpr ( CTree )
static
static bool Puma::CSemExpr::isLvalue ( CTree )
static
bool Puma::CSemExpr::isModifiable ( CTypeInfo type,
unsigned long  pos = 0 
)
inlinestatic
bool Puma::CSemExpr::isPtrToObj ( CTypeInfo type,
unsigned long  pos = 0 
)
inlinestatic
bool Puma::CSemExpr::known_here ( CObjectInfo ,
unsigned long  int 
) const
protected
CObjectInfo* Puma::CSemExpr::lookup ( CT_SimpleName ,
SemObjType  ,
bool  = false 
) const
protected
CObjectInfo* Puma::CSemExpr::lookup ( const char *  ,
CStructure ,
SemObjType  ,
bool  ,
unsigned long  int 
) const
protected
LONG_LONG Puma::CSemExpr::next_character ( const char *&  ,
bool &   
) const
CObjectInfo* Puma::CSemExpr::nextMember ( CStructure ,
CObjectInfo  
) const
protected
void Puma::CSemExpr::overflow ( CTree ,
int  ,
bool &   
) const
static void Puma::CSemExpr::passOnConstant ( CTree node,
CTree base,
CTypeInfo t1 
)
static
void Puma::CSemExpr::popSubObj ( CTypeInfo *&  ,
CObjectInfo *&  ,
CObjectInfo *&  ,
Stack< SubObj > &   
) const
protected
static CTypeInfo* Puma::CSemExpr::promote ( CTree ,
CTree  
)
static
void Puma::CSemExpr::pushSubObj ( CTypeInfo *&  ,
CObjectInfo *&  ,
Stack< SubObj > &   
) const
protected
CTypeInfo* Puma::CSemExpr::resolve ( CTree ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_SimpleName ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_String ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_WideString ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_CmpdLiteral ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_Bool ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_Character ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_WideCharacter ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_Integer ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_Float ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_BracedExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_BinaryExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_UnaryExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_AddrExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_DerefExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_PostfixExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_IndexExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_SizeofExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_AlignofExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_OffsetofExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_IfThenExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_CastExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_CallExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolve ( CT_MembPtrExpr ,
CTree  
)
CTypeInfo* Puma::CSemExpr::resolveExpr ( CTree expr,
CTree base = (CTree *) 0 
)
void Puma::CSemExpr::resolveInit ( CObjectInfo ,
CTree ,
CTree ,
bool  = false 
)
void Puma::CSemExpr::resolveInit ( CObjectInfo ,
CTree ,
CTree ,
bool  ,
Stack< SubObj > &   
)
protected
int Puma::CSemExpr::scan_character ( CTree ,
LONG_LONG  
) const
void Puma::CSemExpr::singleExprInit ( CTree ,
CTree ,
CTypeInfo ,
bool   
)
protected
CObjectInfo* Puma::CSemExpr::Type ( const char *  ,
CStructure ,
SemObjType  ,
unsigned long  int 
) const
protected

Member Data Documentation

int Puma::CSemExpr::conv_to_ptr
protected
CStructure* Puma::CSemExpr::current_scope
protected
ErrorSink& Puma::CSemExpr::err
protected



Puma Reference Manual. Created on Thu Mar 13 2014.