00001 #ifndef FIELD_REF_EXPRESSION_H_
00002 #define FIELD_REF_EXPRESSION_H_
00003
00004 #include "expression.h"
00005 #include <string>
00006
00007 namespace il
00008 {
00009 struct record_info;
00010
00011
00016 class field_ref_expression : public il::expression
00017 {
00018 friend class boost::serialization::access;
00019
00020 template<class Archive>
00021 void serialize(Archive & ar, const unsigned int version)
00022 {
00023 ar & boost::serialization::base_object<il::expression>(*this);
00024 ar & inner_exp;
00025 ar & field_info;
00026 }
00027
00028 private:
00029 expression* inner_exp;
00030 record_info* field_info;
00031 public:
00032 field_ref_expression();
00033 field_ref_expression(expression* inner_exp, record_info* field_info,
00034 type* t, location loc);
00035 virtual string to_string() const;
00036 virtual expression* get_inner_expression();
00037 virtual record_info* get_field_info();
00038 virtual ~field_ref_expression();
00039 };
00040
00041 }
00042
00043 #endif