diff --git a/src/Cryptol/Eval/FFI.hs b/src/Cryptol/Eval/FFI.hs index c47d6d363..4accda339 100644 --- a/src/Cryptol/Eval/FFI.hs +++ b/src/Cryptol/Eval/FFI.hs @@ -29,8 +29,9 @@ evalForeignDecls :: ModulePath -> Module -> EvalEnv -> Eval (Either [FFILoadError] EvalEnv) evalForeignDecls path m env = do foreignSrc <- liftIO $ newIORef Nothing - let evalForeignDeclGroup e (Recursive ds) = foldlM evalForeignDecl e ds - evalForeignDeclGroup e (NonRecursive d) = evalForeignDecl e d + let evalForeignDeclGroup e (NonRecursive d) = evalForeignDecl e d + evalForeignDeclGroup _ (Recursive _) = panic "evalForeignDecls" + ["Recursive foreign declaration group"] evalForeignDecl e d = case dDefinition d of DForeign -> do fsrc <- liftIO (readIORef foreignSrc) >>= \case