Just needed to recurse through the parens and infix cases in `appTys`.
This commit is contained in:
Trevor Elliott 2016-04-07 21:26:21 -07:00
parent b875edae1a
commit cf979723b7
3 changed files with 8 additions and 2 deletions

View File

@ -140,8 +140,9 @@ appTys expr ts tGoal =
P.ETyped {} -> mono
P.ETypeVal {} -> mono
P.EFun {} -> mono
P.EParens {} -> tcPanic "appTys" [ "Unexpected EParens" ]
P.EInfix {} -> tcPanic "appTys" [ "Unexpected EInfix" ]
P.EParens e -> appTys e ts tGoal
P.EInfix a op _ b -> appTys (P.EVar (thing op) `P.EApp` a `P.EApp` b) ts tGoal
where mono = do e' <- checkE expr tGoal
(ie,t) <- instantiateWith e' (Forall [] [] tGoal) ts

View File

@ -0,0 +1 @@
:t (split`{a=[3]})`{3}

View File

@ -0,0 +1,4 @@
Loading module Cryptol
[error] at <interactive>:1:2--1:7:
Named and positional type applications may not be mixed.