lean4-htt/library/init
Sebastian Ullrich 8f55ec4c50 fix(init/core): remove out_param from has_pow
With the current elaboration scheme, out_params and coercions do not mix well,
as evidenced by the following example by @digama:

```
variables {α : Type*} [group α]
def gpow : α → ℤ → α := sorry
instance group.has_pow : has_pow α ℤ := ⟨gpow⟩

example (a : α) : a ^ 0 = 1 := sorry -- failed to synth ⊢ has_pow α ℕ
example (a : α) : a ^ (0:ℕ) = 1 := sorry -- ok, coerces
example (a : α) : a ^ (0:ℤ) = 1 := sorry -- ok
```

The issue is that
* we first try to solve `has_pow ?α ?β`, which is postponed
* then infer `?α = nat` from `a`
* then at some point call `elaborator::synthesize()` and default `β` to `nat`
* then try to solve `has_pow nat nat`, which fails at `int =?= nat`
2018-04-04 13:05:59 +02:00
..
algebra refactor(algebra/ordered_field): move theorems from discrete 2018-02-13 10:51:50 -08:00
category fix(init/category/state): lift unintended universe restriction 2018-03-26 13:00:23 +02:00
data fix(init/core): remove out_param from has_pow 2018-04-04 13:05:59 +02:00
meta refactor(library/init/core,library/init/unit): make unit an abbreviation of punit.{0} 2018-03-27 10:33:04 -07:00
cc_lemmas.lean feat(frontends/lean): use . for field access 2017-03-28 15:29:54 -07:00
classical.lean refactor(init/classical): simplify classical proofs 2017-07-28 16:47:53 +01:00
coe.lean chore(library/init/coe): document why @[reducible] annotation is needed 2018-01-16 11:31:43 -08:00
core.lean fix(init/core): remove out_param from has_pow 2018-04-04 13:05:59 +02:00
default.lean chore(library/native): remove dead code 2018-02-07 17:29:25 -08:00
function.lean feat(init): some simp lemmas 2018-03-01 16:07:52 +01:00
funext.lean refactor(frontends/lean/token_table,library): take ~> assume 2017-07-05 11:20:10 -07:00
init.md chore(*.md): fix/remove broken links 2016-02-23 10:11:24 -08:00
ite_simp.lean feat(library/init/ite_simp): add simp lemmas 2017-11-06 12:34:52 -08:00
logic.lean fix(library/init): add simp lemmas for auto_param and opt_param 2017-12-09 09:59:00 -08:00
propext.lean feat(frontends/lean): add support for t.<id> and t.<idx> when t is a composite term 2017-03-28 17:47:49 -07:00
relator.lean chore(library): remove out notation for out_param 2017-12-15 15:47:58 -08:00
util.lean refactor(library): has_to_string ==> has_repr 2017-06-18 18:29:19 -07:00
version.lean.in chore(leanpkg/lean_version): recognize nightlies as releases separate from master 2018-03-20 15:14:45 -07:00
wf.lean feat(library): provide names for constructor arguments 2017-12-04 16:25:16 -08:00