One feature of #includes that I particularly like is that it allows you to include a generic main() function. Should this also be allowed in modules? I hope so.[1]
#including a main() function is particularly useful in cases where you have N different binaries all following the same basic template. The most obvious example of this is when writing unit tests. A developer might have a whole bunch of separate binaries for testing various projects (or parts of a given project), and all of these should have the same entry point, with the same command-line args, etc. As a developer of a unit test framework, I'd want users of the library to be able to #include (or import) the appropriate file/module and get a main() function for free.
Granted, it would be a simple matter of writing a main() function for each binary that just forwards on to the real implementation inside the module, but that's not required when using #includes, and so it would make it considerably less enticing to migrate to modules in a case like this.
- Jim
[1] Some of this is probably an implementation issue: for instance, Linux is
perfectly happy with main() coming from a shared library, however (as far
as I know), neither Mac or Windows will allow this.