lean4-htt/src/kernel
Leonardo de Moura c4c548dc5d feat(*): simplify interrupt propagation
Instead of having m_interrupted flags in several components. We use a thread_local global variable.
The new approach is much simpler to get right since there is no risk of "forgetting" to propagate
the set_interrupt method to sub-components.

The plan is to support set_interrupt methods and m_interrupted flags only in tactic objects.
We need to support them in tactics and tacticals because we want to implement combinators/tacticals such as (try_for T M) that fails if tactic T does not finish in M ms.
For example, consider the tactic:

    try-for (T1 ORELSE T2) 5

It tries the tactic (T1 ORELSE T2) for 5ms.
Thus, if T1 does not finish after 5ms an interrupt request is sent, and T1 is interrupted.
Now, if you do not have a m_interrupted flag marking each tactic, the ORELSE combinator will try T2.
The set_interrupt method for ORELSE tactical should turn on the m_interrupted flag.

Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2013-11-12 21:45:48 -08:00
..
abstract.cpp Use fullpath in #include directives, add missing STL headers 2013-09-13 03:35:29 -07:00
abstract.h Use fullpath in #include directives, add missing STL headers 2013-09-13 03:35:29 -07:00
builtin.cpp feat(kernel): heterogeneous transitivity axiom, we need this axiom to be able to generate modular proofs in the rewriting engine module 2013-10-29 17:07:30 -07:00
builtin.h feat(kernel): heterogeneous transitivity axiom, we need this axiom to be able to generate modular proofs in the rewriting engine module 2013-10-29 17:07:30 -07:00
CMakeLists.txt feat(replace_visitor): add an abstract class for applying transformations on expressions 2013-10-23 15:01:37 -07:00
context.cpp feat(kernel/context): add method for remove context entries at positions [s, s+n). 2013-10-22 15:52:24 -07:00
context.h feat(kernel/context): add method for remove context entries at positions [s, s+n). 2013-10-22 15:52:24 -07:00
environment.cpp feat(*): simplify interrupt propagation 2013-11-12 21:45:48 -08:00
environment.h feat(*): simplify interrupt propagation 2013-11-12 21:45:48 -08:00
expr.cpp chore(*): add LCOV_EXCL_LINE to lean_unreachable statements 2013-11-11 09:19:38 -08:00
expr.h fix: add '#include <tuple>' 2013-11-03 13:00:42 -05:00
expr_eq.h chore(*): add LCOV_EXCL_LINE to lean_unreachable statements 2013-11-11 09:19:38 -08:00
expr_maps.h Use fullpath in #include directives, add missing STL headers 2013-09-13 03:35:29 -07:00
expr_sets.h Use fullpath in #include directives, add missing STL headers 2013-09-13 03:35:29 -07:00
for_each.h feat(kernel/for_each): add option for disabling cache of atomic expressions 2013-10-25 15:25:17 -07:00
formatter.cpp refactor(kernel): move printer and formatter objects to the kernel 2013-10-22 08:15:36 -07:00
formatter.h feat(*): simplify interrupt propagation 2013-11-12 21:45:48 -08:00
free_vars.cpp chore(*): add LCOV_EXCL_LINE to lean_unreachable statements 2013-11-11 09:19:38 -08:00
free_vars.h Simplify metavariable context. Now, we have only 'lift' and 'inst' instead of 'subst', 'lift' and 'lower' 2013-09-16 19:32:28 -07:00
instantiate.cpp feat(kernel/expr): add new mk_app template for creating applications using a collection 2013-10-27 08:53:58 -07:00
instantiate.h refactor(beta_reduction): add function apply_beta 2013-10-23 16:03:52 -07:00
justification.cpp fix(kernel/metavar): add normalize assignment justification 2013-10-27 11:02:34 -07:00
justification.h fix(kernel/metavar): add normalize assignment justification 2013-10-27 11:02:34 -07:00
kernel_exception.cpp fix(kernel/type_checker): add missing test, and kernel_exception has_no_type_exception 2013-11-10 11:14:04 -08:00
kernel_exception.h fix(kernel/type_checker): add missing test, and kernel_exception has_no_type_exception 2013-11-10 11:14:04 -08:00
level.cpp chore(*): add LCOV_EXCL_LINE to lean_unreachable statements 2013-11-11 09:19:38 -08:00
level.h Implement total order on expressions 2013-09-24 12:16:32 -07:00
metavar.cpp refactor(kernel/metavar): avoid using unique names for default metavariable prefix 2013-11-07 10:16:25 -08:00
metavar.h style(kernel/metavar): add missing includes 2013-10-29 03:00:43 -07:00
normalizer.cpp feat(*): simplify interrupt propagation 2013-11-12 21:45:48 -08:00
normalizer.h feat(*): simplify interrupt propagation 2013-11-12 21:45:48 -08:00
object.cpp feat(kernel): add weight to kernel definitions 2013-10-15 14:50:08 -07:00
object.h chore(*): add LCOV_EXCL_LINE to lean_unreachable statements 2013-11-11 09:19:38 -08:00
occurs.cpp feat(kernel/for_each): allow function F to interrupt for_each search 2013-10-25 14:58:02 -07:00
occurs.h Use fullpath in #include directives, add missing STL headers 2013-09-13 03:35:29 -07:00
pos_info_provider.cpp feat(pos_info_provider): add position information provider for expressions 2013-10-22 08:15:36 -07:00
pos_info_provider.h feat(pos_info_provider): add position information provider for expressions 2013-10-22 08:15:36 -07:00
printer.cpp refactor(kernel/metavar): avoid using unique names for default metavariable prefix 2013-11-07 10:16:25 -08:00
printer.h refactor(kernel): move printer and formatter objects to the kernel 2013-10-22 08:15:36 -07:00
replace.h fix: add '#include <tuple>' 2013-11-03 13:00:42 -05:00
replace_visitor.cpp fix: add '#include <tuple>' 2013-11-03 13:00:42 -05:00
replace_visitor.h feat(replace_visitor): add an abstract class for applying transformations on expressions 2013-10-23 15:01:37 -07:00
threadsafe_environment.h fix(lua): make sure environment objects can be safely accessed/updated from current threads 2013-11-11 20:29:53 -08:00
type_checker.cpp feat(*): simplify interrupt propagation 2013-11-12 21:45:48 -08:00
type_checker.h feat(*): simplify interrupt propagation 2013-11-12 21:45:48 -08:00
type_checker_justification.cpp refactor(kernel): rename trace to justification 2013-10-23 13:42:17 -07:00
type_checker_justification.h refactor(kernel): rename trace to justification 2013-10-23 13:42:17 -07:00
unification_constraint.cpp fix(kernel/unification_constraint): memory leak 2013-10-25 08:06:21 -07:00
unification_constraint.h fix(style): missing include 2013-10-25 08:10:28 -07:00
value.h Modify Doxygen file to extract all elements even the undocumented ones. Disable warnings for undocumented entities. Add extra comments. 2013-09-13 13:46:22 -07:00