New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
unicode char (emoji) considered illegal #898
Comments
Was able to reproduce this. This seems to be a fairly straightforward fix - requires debugging how unicode characters are transformed down the compilation pipeline. We can work backwards step-by-step to see where the incorrect encoding is being produced.
Replace cgLit (MachStr s) = (jlong, genCode) with
(Note: You'll need to add
Let me know if you need further assistance. |
For this particular program, the expected byte sequence should be: |
This was an issue in |
Description
Some valid unicode characters cause a run time error.
Steps to Reproduce
module Main where
emoji = "\x1F600"
main = return ()
When run causes:
Exception in thread "main" java.lang.ClassFormatError: Illegal UTF8 string in constant pool in class file main/Main$emoji
Your Environment
Did you install an older version of Eta/Etlas before?
Yes, but I removed before installing the latest version.
Current Eta & Etlas version:
eta-0.8.6b2.
etlas version 1.5.0.0
compiled using version 2.1.0.0 of the etlas-cabal library
Operating System and version:
macOS Sierra
The text was updated successfully, but these errors were encountered: