Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to C++11 #152

Closed
jmmv opened this issue Nov 21, 2015 · 2 comments
Closed

Switch to C++11 #152

jmmv opened this issue Nov 21, 2015 · 2 comments

Comments

@jmmv
Copy link
Member

jmmv commented Nov 21, 2015

I think it's about time we permit the use of C++11.

A good reason for this is to modernize the codebase and gain code simplicity: range-based for loops and auto types are just so much better than typing iterators and complex types.

However, the real reason is to gain access to std::thread: the current subprocess-based executor model for parallelism is just too complex, and extending it to gain even more parallelism (think running test case listings independently) would make it insane to understand. The current model started as something relatively simple but, with the implementation of the ATF interface, became very hard to manage (try to see how cleanup routines are handled).

The specifics of this bug are to drop utils/shared_ptr.hpp, which will in turn require changes to the Travis configuration to install compilers that do support C++11 in our continuous builds (e.g. upgrade to GCC 4.8). Once that is done, we should be free to start using more interesting C++11 features.

Out of curiosity, I took a look at what Firefox does, which is a program that is widely available, and they do now accept C++11 as well.

jmmv added a commit that referenced this issue Feb 24, 2017
Start by dropping the shared_ptr.hpp compatibility header.  I'm doing
this to free the codebase of using "new" (6-year old, at this point)
features.  In particular, I want to be able to use threads to fix the
parallel execution of test cases.

Fixes #152.
jmmv added a commit that referenced this issue Feb 24, 2017
Start by dropping the shared_ptr.hpp compatibility header.  I'm doing
this to free the codebase of using "new" (6-year old, at this point)
features.  In particular, I want to be able to use threads to fix the
parallel execution of test cases.

Fixes #152.
jmmv added a commit that referenced this issue Feb 24, 2017
To do so, enable support for the C++11 standard during configure and
sanity-check that it works.

Then, and as a first step, change the code to drop the shared_ptr.hpp
compatibility header as proof that this is working.  I'm doing this to
allow the codebase of using "new" (6-year old, at this point) features.
In particular, I want to be able to use threads to fix the parallel
execution of test cases.

Fixes #152.
jmmv added a commit that referenced this issue Feb 24, 2017
To do so, enable support for the C++11 standard during configure and
sanity-check that it works.

Then, and as a first step, change the code to drop the shared_ptr.hpp
compatibility header as proof that this is working.  I'm doing this to
allow the codebase of using "new" (6-year old, at this point) features.
In particular, I want to be able to use threads to fix the parallel
execution of test cases.

Fixes #152.
jmmv added a commit that referenced this issue Feb 24, 2017
To do so, enable support for the C++11 standard during configure and
sanity-check that it works.

Then, and as a first step, change the code to drop the shared_ptr.hpp
compatibility header as proof that this is working.  I'm doing this to
allow the codebase of using "new" (6-year old, at this point) features.
In particular, I want to be able to use threads to fix the parallel
execution of test cases.

Fixes #152.
jmmv added a commit that referenced this issue Feb 24, 2017
To do so, enable support for the C++11 standard during configure and
sanity-check that it works.

Then, and as a first step, change the code to drop the shared_ptr.hpp
compatibility header as proof that this is working.  I'm doing this to
allow the codebase of using "new" (6-year old, at this point) features.
In particular, I want to be able to use threads to fix the parallel
execution of test cases.

Fixes #152.
jmmv added a commit that referenced this issue Mar 10, 2017
To do so, enable support for the C++11 standard during configure and
sanity-check that it works.

Then, and as a first step, change the code to drop the shared_ptr.hpp
compatibility header as proof that this is working.  I'm doing this to
allow the codebase of using "new" (6-year old, at this point) features.
In particular, I want to be able to use threads to fix the parallel
execution of test cases.

Fixes #152.
jmmv added a commit that referenced this issue Mar 17, 2017
To do so, enable support for the C++11 standard during configure and
sanity-check that it works.

Then, and as a first step, change the code to drop the shared_ptr.hpp
compatibility header as proof that this is working.  I'm doing this to
allow the codebase of using "new" (6-year old, at this point) features.
In particular, I want to be able to use threads to fix the parallel
execution of test cases.

Fixes #152.
jmmv added a commit that referenced this issue Mar 19, 2017
To do so, enable support for the C++11 standard during configure and
sanity-check that it works.

Then, and as a first step, change the code to drop the shared_ptr.hpp
compatibility header as proof that this is working.  I'm doing this to
allow the codebase of using "new" (6-year old, at this point) features.
In particular, I want to be able to use threads to fix the parallel
execution of test cases.

Fixes #152.
@ngie-eign
Copy link
Contributor

This is now a hard requirement via bf8eb10.

ngie-eign added a commit to ngie-eign/kyua that referenced this issue Mar 22, 2019
…hpp`

This compatibility header with C++11 and newer. C++11 is now required after
bf8eb10.

This completes freebsd#152.

Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>
ngie-eign added a commit to ngie-eign/kyua that referenced this issue Mar 22, 2019
…hpp`

This compatibility header is not required with C++11 and newer. C++11 is now
required after bf8eb10.

This completes freebsd#152.

Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>
ngie-eign added a commit to ngie-eign/kyua that referenced this issue Mar 22, 2019
…hpp`

This compatibility header is not required with C++11 and newer. C++11 is now
required after bf8eb10.

This completes freebsd#152.

Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>
jmmv pushed a commit that referenced this issue Mar 26, 2019
…hpp`

This compatibility header is not required with C++11 and newer. C++11 is now
required after bf8eb10.

This completes #152.

Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>
@ngie-eign
Copy link
Contributor

Addressed in commits noted above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants