Brendan wrote:
If something takes more than about 3 minutes I end up going for coffee or watching TV or something, getting back 5 minutes after it's finished and by then it takes a further few minutes to figure out what I was doing. I also build frequently (like every 20 minutes or so on average, but sometimes 5 times in 10 minutes) to catch simple errors sooner. Getting the "compile then test, then continue" time down to less than 30 seconds saves a massive amount of time; which is part of the reason I put a lot of work into my little build utility (which is also part of the reason I can build everything so fast - the other part of fast build times is avoiding "slow to compile" languages).
For what I'm aiming for eventually (where executables are compiled when they're first executed) fast build times are just as important for different reasons.
I agree with the fact that the debug cycle time, should be minimized. And that it should preferably be kept in the domain of seconds. However with proper code separation, and intelligent tools, you should only be compiling your changes (and linking the executable), whenever a change was made. If this takes more than a few seconds, then you're doing it wrong.
I do agree with the fact that C++ is waaaay harder to compile than C, indeed if template meta programming is utilized, however if only changes are to be recompiled at each iteration, then this should not be a major issue. I don't mind a full recompilation taking a few minutes if only the debug cycle time is within seconds.
As for 10ms compilation. I honestly have no problem 'waiting' for a few seconds, as I'll likely be thinking meanwhile, but maybe that's just because I'm not a "10ms debug cycle time" kinda guy.
Brendan wrote:
I still think the operator overloading is a trap for people that aren't as familiar with the codebase as the person who wrote the code (which tends to include the person that wrote the code after they've been working on some other project for a few months).
Operator overloading *can* be a trap, that is if it's used non-intuitively. I honestly believe that it allows for cleaner code, indeed in terms of linear algebra, because it allows you to express what you do in math, that is it allows you to use the multiplication symbol, when you use it in math.
And being able using the multiplication operator, when you expect to be able to use it, e.g. for multiplying matrices, allows you to not know the codebase at all, but rely on the common understanding of the underlaying mathematical construct, or as we like to refer to it; The interface. - That is your now coding against the mathematically accepted interface, rather than some implementation specific one, which may or may not throw implementation specific details, parameters and such at you.
To quote a rather intelligent fella on this forum;
Brendan wrote:
Complexity is the single largest problem facing programmers.
I truly agree with this statement! - And that's why would should hide all the complexity of implementations behind interfaces. Operator overloading can help us provide a intuitive interface. Templates can help us provide a generic and common interface for specialized implementations. - Both of these are complex to implement, but easy to use. And that's the main point here, the burden is on the implementer, and not on the user.
If I want to use a list, then all I want is to be able to store my data (the interface), how the data is stored is up to the implementation, which I expect to do the right thing, i.e. split my data into hot and cold sections, ect.
If I want to multiply vectors, then I'll just use the multiplication operator (the interface), and it's up to the implementation to do it, in the optimal way given the available hardware, ect.
Brendan wrote:
I'm not hung up on C++. Any language that is pointlessly overcomplicated and harder to learn, use, debug, read or compile is bad; and I'm sure I've complained about plenty of other languages in the past. The only reason I haven't complained about C# (which is where this discussion started) is that C# is much cleaner/easier than C++ in just about every possible way.
I actually agree with you on this, C++ is an overcomplicated language, and it is hard to learn, use, debug, ect., and honestly one of the main reasons why C++ is overly complicated is because of it's backwards compatibility with C, and the fact that C++ is a multi-paradigm language.
I do however believe that the recent standards of C++, namely 11 and 14, has helped out quite a bit on this front, and the ISO committee is clearly aware of the issue. Also C++17 is going to be a large step forward.
That being said, there are thing which are a lot simpler to handle in C++ than in C, say; exception handling (even though I know that you do not agree on this), resource handling (mostly due to RAII), generic code & reusability (due to template), ect.
I do not want to get into a discussion about this, because I know we'll never come to an agreement, about which is better.
However I'd like to point out, that while I do something think you're a bit stubborn at times, then I do think, that you've really hit the nail on the head with you answer to Kevin, in terms of breaking through with ones OS, and I'd like to applause you on the fact that you're trying out new stuff, if your goal is to change the world of OSes. However I'm convinced not everyone is trying to break through with their OS, mine is really just past time programming.