4 ms·
[ Full disclosure: CMake developer. ] That presumes that we knew it would have been such a problem when CMake was started (back in the late 90's; I started con
by mathstuf 5y ago
[ Full disclosure: CMake developer. ]
That presumes that we knew it would have been such a problem when CMake was started (back in the late 90's; I started contributing in 2010). The issue is that a lot of semantics are tied up in the way the language works between the list representation, variable lookup, scoping, policies, etc.
- kstenerud 5y agoPerhaps it's time to cut your losses, throw out the syntax and build a new one? With a solid engine underneath this should in theory be feasible? I once contributed to and even built a number of projects using CMake, but have since vowed that I'll never EVER open another CMakeLists.txt again, and will toss any CMake-based project that has builder errors I'd otherwise have to debug. CMake is the only build system of the dozens I've used over the last 30 years that has driven me to this. For awhile I held up hope with the advent of "Modern CMake", but alas it's not enough to fix things, and I doubt the syntax could ever be fixed.
- krapht 5y agoStrong "just rewrite it in Rust" attitude coming through here.
- kstenerud 5y agoWhy would you rewrite it in rust? The engine is in C++. It's only the syntax part that's broken. So a new parser, new AST handling code, some engine section overhauls here and there to match the new reality. And they could even separate the engine from the syntax while they're at it, making it even more powerful. Simple? No. Necessary? Yes. The alternative is to keep smearing more and more lipstick on the pig and hope people don't keep abandoning it, which is a shame because CMake COULD be great.
- mathstuf 5y agoIt's not only the syntax that is broken. The "type system" has quite a few holes in it because of the language. Many of them have no counterpart in other languages either. It would, for example, most likely still be stringly typed, so list representations would still get baked down into `;`-separated lists with all the problems that entails.