File tree 2 files changed +8
-3
lines changed
2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ import Options.Applicative.Help.Pretty as O
16
16
import System.Directory (createDirectoryIfMissing )
17
17
import qualified System.FilePath as FP ((-<.>) , takeDirectory )
18
18
19
+ import Ohua.ALang.Lang
19
20
import Ohua.Frontend.NS
20
21
import Ohua.CodeGen.Iface
21
22
import qualified Ohua.CodeGen.JSONObject as JSONGen
@@ -172,7 +173,11 @@ main = do
172
173
mainMod <-
173
174
registerAnd modTracker (rawMainMod ^. name) $
174
175
loadDepsAndResolve modTracker rawMainMod
175
- expr <- getMain $ mainMod ^. decls
176
+ expr' <- getMain $ mainMod ^. decls
177
+ let expr = case expr' of
178
+ -- FIXME this is technically not correct for edge cases
179
+ Lambda " _" body -> body
180
+ e -> e
176
181
let sfDeps = gatherSFDeps expr
177
182
let (mainArity, completeExpr) = mainToEnv expr
178
183
gr <-
@@ -194,7 +199,7 @@ main = do
194
199
, entryPointName = entrypoint
195
200
, entryPointNamespace = rawMainMod ^. name
196
201
}
197
- let outputPath = fromMaybe ( nameSuggest) out
202
+ let outputPath = fromMaybe nameSuggest out
198
203
liftIO $
199
204
createDirectoryIfMissing
200
205
True
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ packages:
3
3
- .
4
4
- location :
5
5
git : https://github.com/ohua-dev/ohua-core
6
- commit : 2933632f8dfcc39ca52c43e50a901b7193955a59
6
+ commit : 2da314763bb839ef0c0f7f191382f266455c26c6
7
7
subdirs : [core]
8
8
extra-dep : true
9
9
- location :
You can’t perform that action at this time.
0 commit comments