-
Notifications
You must be signed in to change notification settings - Fork 43
Description
I'm trying to get hint going with an experimental live coding editor for music (https://github.com/yaxu/feedforward), running on a raspberry pi zero computer (running raspbian stretch, with ghc 8.0.1, on an armv6 processor).
It works, but only from runhaskell/ghci, and not when compiled. Here's what happens when I try to run the example:
pi@lcd:~/src/hint/examples $ ./example
Load SomeModule.hs
Put the Prelude, Data.Map and *SomeModule in scope
Data.Map is qualified as M!
Now we can query the type of an expression
e.g. typeOf M.singleton (f, g, h, 42)
Num t => a -> M.Map ([a1] -> a1, [a2] -> a2, [a3] -> a3, t) a
Observe that f, g and h are defined in SomeModule.hs, but f is not exported. Let's check it...
[Fun "g",Fun "h"]
We can also evaluate an expression; the result will be a string
e.g. eval "length $ concat [[f,g],[h]]"
Illegal instruction
As I say, it's fine when run with runhaskell or from a ghci prompt. I have the same with my hint-driven text editor - it's fine (but of course slow) from runhaskell, but I get an Illegal instruction error when interpreting something with hint, via a binary compiled with ghc.
I don't know much about this stuff, but think the problem is probably with the armv6 port of ghc. My efforts in trying to compile a newer ghc for raspbian have not been successful though..
So I thought I'd ask here - any possibility that the problem could be with hint in particular rather than ghc in general? Any pointers much appreciated!