#ifndef EMPATHY_BUILTINS_TYPES_TEMPLATE_TDECL_H #define EMPATHY_BUILTINS_TYPES_TEMPLATE_TDECL_H namespace empathy::builtins { class TDecl { public: template< typename T, typename V > TDecl( T&& type, V&& value ) : m_type( forward< T >( type ) ), m_value( forward< V >( value ) ) {} const auto& type() const { return m_type; } const auto& value() const { return m_value; } private: Term m_type; Term m_value; }; extern bool IsTDecl( const Value& td ); } namespace empathy::ir { template<> struct Bridge< builtins::TDecl > { static const Term& Type(); static Value ToValue( const builtins::TDecl& td ); static optional< builtins::TDecl > FromValue( const Value& v ); }; } #endif