Leonardo de Moura
1e1a085ab3
test: eq theorem derivation
2021-09-09 17:51:49 -07:00
Leonardo de Moura
7607a24469
test: deriving DecidableEq for enum types
...
Forgot to add test.
2021-09-09 17:47:23 -07:00
Leonardo de Moura
09eecc5c08
fix: simp was not applying rewrites to the function application prefixes
2021-09-09 17:07:14 -07:00
Leonardo de Moura
5a7badd69a
feat: add support for erasing keyed attributes
...
This commit addresses any issue described at https://leanprover.zulipchat.com/#narrow/stream/270676-lean4/topic/Eq.2Endrec.20vs.20Eq.2Erec
2021-09-09 14:28:41 -07:00
Leonardo de Moura
4087525cba
feat: add delta tactic
2021-09-09 13:07:33 -07:00
Leonardo de Moura
193d4dc9f5
feat: optimized deriving DecidableEq for enumeration types
...
The proof term is liner on the number of constructors, but type
checking is not linear because the reduction engine in the kernel is
not efficient.
2021-09-08 16:21:32 -07:00
Leonardo de Moura
9b0dfc4b90
feat: convert "orphan" kernel nat literals n into ofNat n
2021-09-08 14:58:13 -07:00
Christian Pehle
bd02f16b43
feat: optimized ``deriving BEq`` for enumeration types
2021-09-08 14:57:21 -07:00
Leonardo de Moura
716ffecf89
chore: add sorry tactic
2021-09-08 08:10:37 -07:00
Leonardo de Moura
c1573d15c1
test: missing tests
2021-09-08 08:00:36 -07:00
Leonardo de Moura
12af1480d6
feat: add specialize tactic
2021-09-08 08:00:02 -07:00
Leonardo de Moura
3fc226dc6d
chore: fix tests
2021-09-07 19:14:30 -07:00
Leonardo de Moura
750c2507da
test: add *> laziness test
...
This commit also fixes a broken test
Closes #617
The following operators are now lazy: `<|>`, `>>`, `*>`, `<*`, `<*>`
2021-09-07 18:03:15 -07:00
Leonardo de Moura
51b7c4cf21
chore: remove Nondet.lean
...
It was too "unsafe", and it is dead code.
2021-09-07 17:36:20 -07:00
Leonardo de Moura
6ea7869c6a
chore: "fix" <|> notation declaration
...
The `infix` declaration was generating a delaborator, but it is
producing the invalid term
```
ConstantFunction.f myFun 3 <|> fun _ => ConstantFunction.f myFun 4
```
It is invalid because the `macro_rules` for `<|>` is based on
`binop_lazy%` which introduces the `fun _ =>` for us.
I tried to use
```
notation:20 a:21 " <|> " b:20 => HOrElse.hOrElse a fun _ : Unit => b
```
but the delaborator generator does not work for this case.
2021-09-07 17:29:27 -07:00
Leonardo de Moura
eb94e87195
chore: fix some tests
2021-09-07 17:20:21 -07:00
Leonardo de Moura
c5f9113dcf
test: use <|> at binop_lazy test
2021-09-07 17:10:36 -07:00
Leonardo de Moura
55f01fb6e1
feat: elaborate binop_lazy%
2021-09-07 13:30:09 -07:00
Leonardo de Moura
f46eedac84
fix: fixes #655
2021-09-07 12:17:28 -07:00
Leonardo de Moura
c93982d10c
chore: disable pp.analyze for now
...
see #651
2021-09-07 07:51:43 -07:00
Daniel Selsam
b36baa143f
feat: improved name-unresolving in delab
...
Fixes #641
2021-09-07 16:26:00 +02:00
Leonardo de Moura
70f2200778
chore: remove enum command
...
Now, `inductive` is also efficient for big enumeration types
2021-09-06 12:01:37 -07:00
Leonardo de Moura
fc334ffbee
fix: pattern matching on UInt
2021-09-05 19:15:59 -07:00
Leonardo de Moura
fa94ce0660
chore: fix test output
2021-09-05 17:49:03 -07:00
Leonardo de Moura
6f075e6ece
feat: add enum command for declaring enumeration types
...
closes #654
2021-09-05 16:58:49 -07:00
Leonardo de Moura
c3bb948009
feat: ignore nested proofs in patterns
2021-09-05 15:46:03 -07:00
Leonardo de Moura
029c5b74a2
feat: ignore implicit arguments at congr conv tactic
2021-09-05 09:44:52 -07:00
Leonardo de Moura
d3c487ddbf
feat: change lhs and rhs conv tactic semantics
...
They can now be applied to non binary applications.
2021-09-05 09:29:40 -07:00
Leonardo de Moura
ef8aadcbea
fix: fixes #653
2021-09-04 18:42:33 -07:00
Leonardo de Moura
aedc706e7d
feat: in modifier at conv tactic
...
It is just a macro for `pattern`
2021-09-04 18:20:33 -07:00
Leonardo de Moura
41cfef5bc4
feat: add pattern conv tactic
2021-09-04 18:02:46 -07:00
Leonardo de Moura
53a3831fd5
feat: add apply conv macro
2021-09-03 20:23:15 -07:00
Leonardo de Moura
94bc386fb4
feat: remark goals as conv goals at the end of nested tactic block
2021-09-03 19:52:51 -07:00
Leonardo de Moura
6988560177
feat: apply allGoals (try rfl) at end of conv nested blocks
2021-09-03 19:21:34 -07:00
Leonardo de Moura
229373a7e6
chore: fix test
2021-09-03 18:59:13 -07:00
Leonardo de Moura
e6c9da0fcc
feat: add support for implication at congr conv tactic
2021-09-03 18:50:19 -07:00
Leonardo de Moura
44e7033c27
feat: add support for forall_congr at conv
2021-09-03 16:57:15 -07:00
Leonardo de Moura
3f70bc543f
feat: add simp conv tactic
2021-09-03 12:06:29 -07:00
Leonardo de Moura
75b8d9aa86
feat: add support for classes with a prefix of outParams at deriving ...
2021-09-03 11:33:09 -07:00
Leonardo de Moura
bbb74bfd9a
feat: elaborate optional deriving after def
2021-09-03 10:22:17 -07:00
Leonardo de Moura
8a268e184b
feat: update def parser with optional deriving ...
2021-09-03 09:42:17 -07:00
Leonardo de Moura
35c0cc3c91
feat: deriving support for type aliases
2021-09-03 09:33:01 -07:00
Leonardo de Moura
8a249bddd2
feat: add try rfl at end of convTarget
2021-09-03 08:14:47 -07:00
Leonardo de Moura
18bcc458d0
feat: add 'enter' conv tactic macro
2021-09-03 08:11:37 -07:00
Leonardo de Moura
b5b5ef6fdf
feat: add funext conv tactic
2021-09-03 08:00:37 -07:00
Leonardo de Moura
95b83ac2c0
feat: add 'conv at .. => ..' support
2021-09-02 19:40:08 -07:00
Leonardo de Moura
7b8ee8f9d8
feat: add 'change' conv tactic
2021-09-02 19:26:25 -07:00
Leonardo de Moura
397774157f
feat: nested tactic support in conv mode
2021-09-02 19:12:05 -07:00
Leonardo de Moura
41ce24e2c6
feat: add done and traceState conv tactics
2021-09-02 18:46:03 -07:00
Leonardo de Moura
33361929b9
feat: add rewrite conv tactic
2021-09-02 18:13:19 -07:00