danielknobe/blobbyvolley2

Moving to C++14

Opened this issue · 4 comments

ngc92 commented

Can we increase the minimum compiler requirements to having C++14 support, or are we targeting a platform where that is not possible?
Would give us e.g. std::make_unique, to finally get rid of all the explicit new still going on in the code.

All "official" targets now support C++14, so except for the theoretical case of someone else compiling for a platform with old compilers, there is nothing wrong with doing so.

Feel free to switch to C++14 if there is a good reason in your opinion.

ngc92 commented

It seems that the code in its current state is in any case no longer compatible with very old versions of GCC
(the codeconventions document claims 4.6, but builds fail with 5.0)
https://github.com/danielknobe/blobbyvolley2/runs/8284234768?check_suite_focus=true

The oldest gcc that currently appears to work is GCC-6:
https://github.com/danielknobe/blobbyvolley2/runs/8284344973?check_suite_focus=true
which I think already as full C++14 support.
Edit: Yes, g++-6 actually made -std=gnu++14 the default mode.

Update: The oldest gcc that currently appears to work is GCC-5
With minor changes we can get GCC-4 up and running. We decided to not support GCC-4 anymore.

If we want to switch to C++14 we need some good reasons. I think std::make_unique is not a game changer.

I think the only open issues for 1.1 are #106 & #124 .
We can fix both by moving union3. Since it is your bot you can better judge if this should be done.

More important: In my opinion the bots in stupid mode are to strong. A beginner will be very frustrated.