Line 480... |
Line 480... |
{};
|
{};
|
|
|
virtual void Emit(FILE * out);
|
virtual void Emit(FILE * out);
|
virtual void EmitValue(FILE * out, TypeName * tn);
|
virtual void EmitValue(FILE * out, TypeName * tn);
|
|
|
int InitAutovar(FILE * out, SUW suw);
|
int InitAutovar(FILE * out, TypeName * type);
|
|
int ElementCount() const;
|
|
|
private:
|
private:
|
Expression * skalar_value;
|
Expression * skalar_value;
|
InitializerList * array_value;
|
InitializerList * array_value;
|
};
|
};
|
Line 669... |
Line 670... |
size(-1)
|
size(-1)
|
{ };
|
{ };
|
|
|
int Emit(FILE * out, const char * struct_name, int pos, bool is_union);
|
int Emit(FILE * out, const char * struct_name, int pos, bool is_union);
|
TypeName * GetMemberType(const char * struct_name, const char * member);
|
TypeName * GetMemberType(const char * struct_name, const char * member);
|
|
TypeName * GetMemberType(int pos);
|
int GetMemberPosition(const char * struct_name,
|
int GetMemberPosition(const char * struct_name,
|
const char * member, bool is_union) const;
|
const char * member, bool is_union) const;
|
int GetSize() const { assert(size != -1); return size; };
|
int GetSize() const { assert(size != -1); return size; };
|
|
|
TypeSpecifier * GetSpecifier() const { return decl_specifiers; };
|
TypeSpecifier * GetSpecifier() const { return decl_specifiers; };
|
StructDeclaratorList * GetDeclarators() const { return struct_decl_list; };
|
StructDeclaratorList * GetDeclarators() const { return struct_decl_list; };
|
TypeName * FirstUnionMember(int size) const;
|
TypeName * FirstUnionMember(int size) const;
|
|
int GetDeclaratorCount() const
|
|
{ return StructDeclaratorList::Length(struct_decl_list); };
|
|
|
private:
|
private:
|
TypeSpecifier * decl_specifiers;
|
TypeSpecifier * decl_specifiers;
|
StructDeclaratorList * struct_decl_list;
|
StructDeclaratorList * struct_decl_list;
|
int size;
|
int size;
|
};
|
};
|
|
TypeName * GetMemberType(StructDeclarationList * sdl, int pos);
|
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
class TypeSpecifier : public Node
|
class TypeSpecifier : public Node
|
{
|
{
|
public:
|
public:
|
// all types
|
// all types
|