C++11

Everything about development and the OpenMW source code.
User avatar
Jyby
Posts: 406
Joined: 10 Dec 2013, 04:16

Re: C++11

Post by Jyby » 05 Jul 2014, 21:28

Can this be a 0.32.0 thing? We should move towards this.
Macbook Air 2013 - 1.7GHz Intel i7 - 8 GB - 512 GB SSD - Intel HD 5000
Windows 10 PC - 4GHz Intel i7 - 16 GB - 512 GB SSD - EVGA GTX 1060 SSC

User avatar
Zini
Posts: 5446
Joined: 06 Aug 2011, 15:16

Re: C++11

Post by Zini » 06 Jul 2014, 08:37

There is still no progress on the Linux side of things.

User avatar
EmperorArthur
Posts: 31
Joined: 17 May 2014, 07:52

Re: C++11

Post by EmperorArthur » 24 Aug 2014, 00:32

Can confirm c++11 compiles on Debian jessie. gcc version 4.9.1 (Debian 4.9.1-4)

I have a patch for niffile.cpp waiting on c++11. It converts recordFactories into a std::map, and uses the find function instead of our current method of manual string compare until a match is found. The problem is the only way I could find to initialize the map was with a braced initializer list, which only works in c++11. :(

Chris
Posts: 1469
Joined: 04 Sep 2011, 08:33

Re: C++11

Post by Chris » 24 Aug 2014, 00:56

EmperorArthur wrote:I have a patch for niffile.cpp waiting on c++11. It converts recordFactories into a std::map, and uses the find function instead of our current method of manual string compare until a match is found. The problem is the only way I could find to initialize the map was with a braced initializer list, which only works in c++11. :(
You can also use a function to initialize it. Like this:
https://github.com/OpenMW/openmw/blob/m ... n.cpp#L139

User avatar
sirherrbatka
Posts: 2121
Joined: 07 Aug 2011, 17:21

Re: C++11

Post by sirherrbatka » 20 Jun 2015, 09:34

*cough* *cough*

Can someone remind me what is holding us from using C++11?

User avatar
Zini
Posts: 5446
Joined: 06 Aug 2011, 15:16

Re: C++11

Post by Zini » 20 Jun 2015, 10:41

Not much. But don't want to change too many things at the same time. We will move to C++11 after the OSG port is done.

User avatar
sirherrbatka
Posts: 2121
Joined: 07 Aug 2011, 17:21

Re: C++11

Post by sirherrbatka » 20 Jun 2015, 13:55

That makes sense. Thanks for answer.

User avatar
Zini
Posts: 5446
Joined: 06 Aug 2011, 15:16

Re: C++11

Post by Zini » 06 Jul 2015, 13:18

Started to look into the C++11 transition again.

I found a section the cmake scripts that checks for g++ 4.6 or newer. I presume that is just a leftover. Or does anyone still uses a g++ older than 4.6? That would seriously limit our options.

Also, what is the oldest version of boost we still need to support? Anything older than 1.51 still in use?

User avatar
psi29a
Posts: 4078
Joined: 29 Sep 2011, 10:13
Github profile: https://github.com/psi29a/
Contact:

Re: C++11

Post by psi29a » 06 Jul 2015, 13:28

Zini wrote:Also, what is the oldest version of boost we still need to support? Anything older than 1.51 still in use?
Well... because travis-ci requires precise, we're still using its default boost libraries.

- Boost version: 1.46.1

-- The CXX compiler identification is GNU 4.6.3
-- The C compiler identification is GNU 4.6.3

User avatar
Zini
Posts: 5446
Joined: 06 Aug 2011, 15:16

Re: C++11

Post by Zini » 07 Jul 2015, 08:36

No problem. I can deal with the boost issue. I guess no one depends on anything older? Then I can as well throw out the check for 4.6.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest