3 ms·
They are not modules. Here is a short list of things that you can't do with these C structs. Modules can be "opened", they can store types, and they can be com
by mpu 12y ago
They are not modules.
Here is a short list of things that you can't do with these C structs. Modules can be "opened", they can store types, and they can be compiled efficiently (calling a function in a struct will always cost an indirection). Also, a proper implementation of modules would allow to obsolete the pre-processor and header files, this is not solved by your proposal.
In short, your solution is no different than prefixing each function name with the "module" name, M_foo, M_bar,...
You can look at (this)[http://llvm.org/devmtg/2012-11/Gregor-Modules.pdf http://llvm.org/devmtg/2012-11/Gregor-Modules.pdf] for a better proposal.