lean2/src/library/elaborator/elaborator_exception.h
Leonardo de Moura 13531b7d3e refactor(kernel): rename trace to justification
Motivations:

- We have been writing several comments of the form "... trace/justification..." and "this trace object justify ...".
- Avoid confusion with util/trace.h

Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2013-10-23 13:42:17 -07:00

26 lines
737 B
C++

/*
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
#include "util/exception.h"
#include "kernel/justification.h"
namespace lean {
/**
\brief Elaborator and related components store the reason for
failure in justification objects.
*/
class elaborator_exception : public exception {
justification m_justification;
public:
elaborator_exception(justification const & j):m_justification(j) {}
virtual ~elaborator_exception() {}
virtual char const * what() const noexcept { return "elaborator exception"; }
justification const & get_justification() const { return m_justification; }
};
}