fix: closes #111
This commit is contained in:
parent
50327205c9
commit
3f32d9eb0b
2 changed files with 14 additions and 3 deletions
|
|
@ -217,9 +217,9 @@ private partial def elabAppArgsAux : ElabAppArgsCtx → Expr → Expr → TermEl
|
|||
if h : ctx.argIdx < ctx.args.size then do
|
||||
argElab ← elabArg ctx.ref e (ctx.args.get ⟨ctx.argIdx, h⟩) d;
|
||||
elabAppArgsAux { argIdx := ctx.argIdx + 1, .. ctx } (mkApp e argElab) (b.instantiate1 argElab)
|
||||
else match d.getOptParamDefault? with
|
||||
| some defVal => elabAppArgsAux ctx (mkApp e defVal) (b.instantiate1 defVal)
|
||||
| none =>
|
||||
else match ctx.explicit, d.getOptParamDefault? with
|
||||
| false, some defVal => elabAppArgsAux ctx (mkApp e defVal) (b.instantiate1 defVal)
|
||||
| _, _ =>
|
||||
-- TODO: tactic auto param
|
||||
if ctx.namedArgs.isEmpty then
|
||||
finalize ()
|
||||
|
|
|
|||
11
tests/lean/run/111.lean
Normal file
11
tests/lean/run/111.lean
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
import Init.Lean
|
||||
new_frontend
|
||||
open Lean
|
||||
#check mkNullNode -- Lean.Syntax
|
||||
#check mkNullNode #[] -- Lean.Syntax
|
||||
#check @mkNullNode
|
||||
#check
|
||||
let f : Array Syntax → Syntax := @mkNullNode;
|
||||
f #[]
|
||||
|
||||
#check let f := @mkNullNode; f #[]
|
||||
Loading…
Add table
Reference in a new issue