fix(frontends/lean): make all variables/parameters visible for 'variables' command

This commit is contained in:
Leonardo de Moura 2014-10-08 13:12:42 -07:00
parent 757cb46579
commit eab9321a3b
2 changed files with 16 additions and 1 deletions

View file

@ -203,7 +203,7 @@ static environment variables_cmd_core(parser & p, variable_kind k) {
expr type = p.parse_expr();
p.parse_close_binder_info(bi);
level_param_names ls = to_level_param_names(collect_univ_params(type));
list<expr> ctx = locals_to_context(type, p);
list<expr> ctx = p.locals_to_context();
for (auto id : ids) {
// Hack: to make sure we get different universe parameters for each parameter.
// Alternative: elaborate once and copy types replacing universes in new_ls.

15
tests/lean/run/mor.lean Normal file
View file

@ -0,0 +1,15 @@
-- Copyright (c) 2014 Floris van Doorn. All rights reserved.
-- Released under Apache 2.0 license as described in the file LICENSE.
-- Author: Floris van Doorn
import algebra.category
open eq eq.ops category
namespace morphism
section
parameter {ob : Type}
parameter {C : category ob}
variables {a b c d : ob} {h : mor c d} {g : mor b c} {f : mor a b}
end
end morphism