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
removed circular requires #63
Conversation
Cool thanks, I've been meaning to do that. Looks mostly good, except you're changing the public api a lot, which is bad and unnecessary. I'll address some of them inline, but also, all the changes to
What does that mean exactly? node-ffi is a native module so I'm confused. |
@@ -7,41 +7,6 @@ var bindings = require('./bindings') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did you change the name of this file? It's the entry point to the module as described in the package.json
, so with it renamed the entry point is missing.
by 'native module' I meant 'core native', adding libffi as a dependency on core -- its part of a personal project. i'll have a go at restoring the public interface now (essentially ffi.js) and revert the tests. |
restored the public api and reverted tests. |
, EXT = ffi.LIB_EXT | ||
, RTLD_NOW = ffi.DynamicLibrary.FLAGS.RTLD_NOW | ||
, RTLD_NOW = DynamicLibrary.FLAGS.RTLD_NOW | ||
, EXT = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of defining this twice (here and in ffi.js), export it here as Library.EXT = EXT
, and then re-export it in ffi.js as ffi.LIB_EXT = ffi.Library.EXT
.
Very good man a couple more things and then it looks great. Also, what's with that |
my bad, I wrongly assumed there was a friendly .gitignore file in the repo. it's cleaned up now together with the duplicate LIB_EXT definitions and type.js comments |
Thanks @justinfreitag, merged in 0a556e9. |
I've gone through lib and test to remove the circular requires that center around ffi.js. My reason for doing this was to get the code (including libffi) working as a native module.