-
Notifications
You must be signed in to change notification settings - Fork 9
avoid multiple export per each module version #15
Conversation
@@ -1,3 +1,6 @@ | |||
// used to avoid exporting same module |
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.
Put comments on same line and use capitalization. Put this variable declaration below the imports please, near where it's used.
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.
hoisting and var
don't work like that and usually var declarations are all on top. Anyway, I don't mind this change.
I don't know if we should be allowing loading multiple versions of the library at the same time. Doesn't seem like a good idea to me. |
I've read this only now. Is there any technical problem or it's just an opinion? I agree but if two modules would like to use Webkit and Webkit2 and they don't know each other I think that should be allowed so it shouldn't be our responsibility to prevent that. What do you think? |
GTK+3 and GTK+2 certainly aren't parallel loadable. WebKit and WebKit2 have different GIR names, so that's different. |
So I dont' understand how are you planning to solve. The problem doesn't seem to be related to this PR, it's the Which one could be a problem? And again, if two modules don't know each other but both load from |
where am I not using four space exactly? |
@magcius do you realize you are commenting randomly things that have been fixed a week ago ... right? |
oh, oops, somehow GitHub showed me an old diff. |
sure, let's just merge this for now. |
avoid multiple export per each module version
Currently, we are repeatedly exporting over and over same module, even if it has been already required elsewhere. This PR ensure every namespace is exported once, improving performance, avoiding duplicated/undesired behaviors (e.g.
GNode.importNS('Gtk') !== GNode.importNS('Gtk')
)