2015-09-29 17:04:11 +00:00
|
|
|
/*
|
|
|
|
Copyright (c) 2015 Microsoft Corporation. All rights reserved.
|
|
|
|
Released under Apache 2.0 license as described in the file LICENSE.
|
|
|
|
|
|
|
|
Author: Leonardo de Moura
|
|
|
|
|
|
|
|
API for accessing the thread local context used by the blast tactic.
|
|
|
|
These procedures can only be invoked while the blast tactic is being executed.
|
|
|
|
|
|
|
|
Remark: the API is implemented in the file blast.cpp
|
|
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "util/sstream.h"
|
2015-10-01 23:21:17 +00:00
|
|
|
#include "library/projection.h"
|
2015-09-29 17:04:11 +00:00
|
|
|
#include "library/blast/state.h"
|
|
|
|
|
|
|
|
namespace lean {
|
|
|
|
namespace blast {
|
|
|
|
/** \brief Return the thread local environment being used by the blast tactic. */
|
|
|
|
environment const & env();
|
|
|
|
/** \brief Return the thread local io_state being used by the blast tactic. */
|
|
|
|
io_state const & ios();
|
|
|
|
/** \brief Return the thread local current state begin processed by the blast tactic. */
|
2015-10-01 23:21:17 +00:00
|
|
|
state & curr_state();
|
|
|
|
/** \brief Return the thead local extension context associated with the blast tactic. */
|
|
|
|
extension_context & ext_ctx();
|
2015-10-02 20:11:17 +00:00
|
|
|
/** \brief Return a thread local fresh name meant to be used to name local constants. */
|
|
|
|
name mk_fresh_local_name();
|
2015-10-01 23:21:17 +00:00
|
|
|
/** \brief Return true iff the given constant name is marked as reducible in env() */
|
|
|
|
bool is_reducible(name const & n);
|
|
|
|
/** \brief Return a nonnull projection_info object if \c n is the name of a projection in env() */
|
|
|
|
projection_info const * get_projection_info(name const & n);
|
|
|
|
|
2015-09-29 17:04:11 +00:00
|
|
|
/** \brief Display the current state of the blast tactic in the diagnostic channel. */
|
|
|
|
void display_curr_state();
|
|
|
|
/** \brief Display message in the blast tactic diagnostic channel. */
|
|
|
|
void display(char const * msg);
|
|
|
|
void display(sstream const & msg);
|
|
|
|
}}
|