Skip to content
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

"Uncaught h$setField: setter not implemented for field: 101" #13

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lprez
Copy link

@lprez lprez commented Dec 23, 2014

When there is a typeclass with more than 101 fields, you get this error before the program starts:

Uncaught h$setField: setter not implemented for field: 101

For example here: https://gist.github.com/ZioCrocifisso/5eb583dc525cd02a097c

@luite
Copy link
Member

luite commented Dec 23, 2014

this does not survive minification with closure compiler in advanced mode

@luite
Copy link
Member

luite commented Jan 4, 2015

do you actually run into this limit? it could be bumped by adding more cases, but a proper solution will probably have to wait until the new codegen has been merged.

@lprez
Copy link
Author

lprez commented Jan 4, 2015

Yes, I do. I have a very big typeclass in my project: https://github.com/ZioCrocifisso/FWGL/blob/experimental/FWGL/Backend/GLES.hs
Anyway, I'm using the version of shims that I put in this commit, therefore it isn't a problem, for now.

@lprez
Copy link
Author

lprez commented Jul 21, 2015

this does not survive minification with closure compiler in advanced mode

It doesn't work anymore:

$ git clone https://gist.github.com/5eb583dc525cd02a097c.git
$ ghcjs -O 5eb583dc525cd02a097c/gistfile1.hs -o out
$ closure --compilation_level ADVANCED_OPTIMIZATIONS out.jsexe/all.js > test.js
$ node test.js

/tmp/test/test.js:154
;break;default:throw"h$setField: setter not implemented for field: "+b;}}funct
                                                                    ^
h$setField: setter not implemented for field: 101

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants