2013-09-01 23:59:15 +00:00
|
|
|
/*
|
|
|
|
Copyright (c) 2013 Microsoft Corporation. All rights reserved.
|
|
|
|
Released under Apache 2.0 license as described in the file LICENSE.
|
|
|
|
|
|
|
|
Author: Leonardo de Moura
|
|
|
|
*/
|
|
|
|
#pragma once
|
2013-09-13 03:04:10 +00:00
|
|
|
#include "kernel/object.h"
|
2013-09-01 23:59:15 +00:00
|
|
|
|
|
|
|
namespace lean {
|
|
|
|
/**
|
|
|
|
\brief Object for tracking coercion declarations.
|
|
|
|
This object is mainly used for recording the declaration.
|
|
|
|
*/
|
|
|
|
class coercion_declaration : public neutral_object_cell {
|
|
|
|
expr m_coercion;
|
|
|
|
public:
|
|
|
|
coercion_declaration(expr const & c):m_coercion(c) {}
|
|
|
|
virtual ~coercion_declaration() {}
|
|
|
|
virtual char const * keyword() const { return "Coercion"; }
|
|
|
|
expr const & get_coercion() const { return m_coercion; }
|
2013-12-28 22:39:10 +00:00
|
|
|
virtual void write(serializer & s) const;
|
2013-09-01 23:59:15 +00:00
|
|
|
};
|
|
|
|
}
|