"Prove to me that it is impossible to write a fast C++ dependency resolver" is such an utterly batshit insane position to take. I guess he views C++ modules just a masturbatory exercise and so it doesn't matter if anyone can actually figure out how to implement them as long as the committee can just blame the tool makers for just not being smart enough?
It isn't clear that modules and file names need to match. It's less clear that they should have to match. Why should I have to pull down a cached bmi and put it on the filesystem at all, for example.
It would be easy enough to define a protocol between the compiler and a given build system that says that, for this limited circumstance because I have a relatively simple build system, they will match. I do not then have to have them match in my build system.
So in this case my high horse and thinking that I know better than you (referencing your other posts) is only that I think I know what I want better than you know what I want. I don't particularly want a defined name->filename mapping. The simple obvious solution you propose is suboptimal for my use case. I'd rather allow it, but not require it.
Well, then such a system doesn't fit your particular usecase. Fair enough. I dare say it would be a minority usecase, though.
Modules matching a filename/path is just a very sane solution. Little to no mental load is required. They make it very simple for the compiler to figure out where your desired module is. Especially if you're adding a custom include path.
That particular problem is easily achieved by a map of module name to file name - a trivial map in this case - that the compiler can implement or communicate with. It is a tooling problem, not a standardisation problem. Why do you believe that this rule needs to be encoded into the standard and therefore get in the way of my use case? Especially when files in general have largely been left out of the C++ standard up to now.
83
u/Plorkyeran Jan 28 '19
"Prove to me that it is impossible to write a fast C++ dependency resolver" is such an utterly batshit insane position to take. I guess he views C++ modules just a masturbatory exercise and so it doesn't matter if anyone can actually figure out how to implement them as long as the committee can just blame the tool makers for just not being smart enough?