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

Documentation around unbound type errors when running ndts #118

Open
ed-alertedh opened this issue Jul 11, 2018 · 0 comments
Open

Documentation around unbound type errors when running ndts #118

ed-alertedh opened this issue Jul 11, 2018 · 0 comments

Comments

@ed-alertedh
Copy link

I am attempting to port some of DCMTK - a fairly complex lib for working with DICOM files - to asm.js using nbind.

One of the main reasons I decided to try nbind was the ability to generate Typescript definitions. When I first started trying to use the ndts tool I got a lot of errors along the lines of "Error: Unbound type 762842? in DSRDocument.write" (see here for method signature). It turned out that all I had to do was bind the classes used in that method signature and even stubs were sufficient as a starting point, i.e.:

NBIND_CLASS(DcmItem) {}
NBIND_CLASS(OFCondition) {}
NBIND_CLASS(DcmStack) {}

If at all possible, it would be great if there was a way to embed the original type information into the asm.js output (in some kind of debug build) so that this error message can be more specific. If that isn't possible then a little documentation and perhaps a hint in the actual error message would be very helpful for people running into this error for the first time. I'm happy to assist if you have some recommendations around the best way to tackle this.

Also, thanks for building such a useful tool!

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

No branches or pull requests

1 participant