Yes, but for some reason the mbed online IDE still doesn’t support C++11.
Apart from PlatformIO, which takes some fiddling still,
we don’t yet have an out-of-the-box IDE with C++11 support that works on mac and Linux.
Besides which, I find that many tutorials and programmers have been slow to catch up with C++11, let alone C++14 or C++17.
Yes, you’re using binary literals. Binary literals were only added in C++14.
That’s expected, GCC supports binary literals as a compiler extension.
Because of the extensions, GNU++98 isn’t the same as C++98.
I find that strange if the binary literals are still present.
I would have thought using C++11 over GNU++11 would disable compiler extensions.
Perhaps it just generates a warning instead?
Yes, perhaps so. I’ll adnit to being overly pedantic at times.
Nor do I sadly, I’ll have to look it up sometime.
I suspect it falls under the umbrella of ‘template substitution’.
Ah, that C++ reference.
When you said the C++ reference I assumed you meant cppreference because it was the only C++ reference that had been mentioned up until that point.
That explains why I couldn’t see the example at cppreference.
Sorry, when you were talking about random
, I assumed you were still talking about compiling for the Pokitto, which does have a random
function.
Aparently random
is in GNU C stdlib.h
for BSD support.
Hrm, interesting.
Particularly given that most of the different implementations tend to start peaking at around the same time.
But this is a case where there’s a provable difference, in which case using an alternative would be justified if that extra performance was neccessary.
Well then, perhaps you’re more intelligent than me too.
Yes, but as I also said, these tend to be less frequent when people have the knowledge to understand the complexities involved and when they check everything through.
Ah yes, Apple’s bug was hilarious.
I’m amazed it got accepted into the production code without being spotted.
The compiler would surely have given an ‘unreachable code detected’ warning.