rgleichman / glance

A visual Haskell
https://www.youtube.com/channel/UCs2gsWfcy83Yqk873WkPfeg
Apache License 2.0
716 stars 15 forks source link

Strange Exception #2

Closed fosskers closed 7 years ago

fosskers commented 7 years ago

Hi there, glance throws the following:

glance-exe: evalPattern: No pattern in case for PBangPat (PVar (Ident "n"))
CallStack (from HasCallStack):
  error, called at app/Translate.hs:249:8 in main:Translate

on this code here

rgleichman commented 7 years ago

Thank you for trying out Glance. At the moment, Glance translates only a subset of Haskell syntax, so this error is completely expected. Bang patterns are currently not-supported, so it is probably failing at line 52 of your code. Try changing work c !n s = do to work c n s = do and then re-running Glance.

For reference, the PBangPat is a constructor for Pat, which is part of haskell-src-exts (see here).

fosskers commented 7 years ago

Yup, works if I remove the bang. Thanks!