PS Lua: compiling ...
pslua: Impossible subexpressions: IfThenElse
CallStack (from HasCallStack):
error, called at src/Relude/Debug.hs:296:11 in relude-1.2.1.0-InE73P0BzGI4tF0Ie3lTIC:Relude.Debug
error, called at lib/Language/PureScript/Backend/Lua/Optimizer.hs:202:17 in pslua-0.1.0.0-2hkO0AwfMEO5Nw1JAHZE53:Language.PureScript.Backend.Lua.Optimizer
How to reproduce
Minimal example I have got:
module Main (main) where
import Prelude (Unit, pure, map)
import Data.Maybe (Maybe(Just, Nothing), maybe)
import Effect (Effect)
import Effect.Exception (throw)
main :: Effect Unit
main =
maybe
(throw "Some error")
pure
(maybe Nothing Just (map (\x -> x) Nothing))
When compiled as a module (e.g. with no entrypoint)
Environment
Template
Based on github.com/purescript-lua-template/commit/9e0920a74d376e61a35be4f7389a6c2758cc1dd3
The error is:
How to reproduce
Minimal example I have got:
When compiled as a module (e.g. with no entrypoint)
Environment
Template
Based on
github.com/purescript-lua-template/commit/9e0920a74d376e61a35be4f7389a6c2758cc1dd3
Compiler
github:Unisay/purescript-lua?rev=cc32d90b291f3d828747b31424db321a23b8f957
This is the version that still works with
purescript-lua-template
, see https://github.com/Unisay/purescript-lua-template/issues/1.Package set
Custom package set, the only difference with the one that
purescript-lua-template
uses is:Which contain a fix for https://github.com/Unisay/purescript-lua/issues/29