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

Transition to C++17 #250

Closed
9 of 10 tasks
rakhimov opened this issue Jan 4, 2018 · 5 comments
Closed
9 of 10 tasks

Transition to C++17 #250

rakhimov opened this issue Jan 4, 2018 · 5 comments
Labels
Milestone

Comments

@rakhimov
Copy link
Owner

rakhimov commented Jan 4, 2018

System:

  • Compiler versions (gcc, clang, icc)
  • Compiler flags (cmake upgrade)
  • Travis-CI (linux, macos)
  • Appveyor-CI (windows mingw64)
  • Qt

Replace Boost:

  • filesystem
  • variant
  • optional
  • string_ref

Docs:

  • Upgrade coding standards
@rakhimov rakhimov added this to the v0.16.2 milestone Jan 4, 2018
rakhimov added a commit that referenced this issue Jan 5, 2018
This also requires upgrade of CMake to 3.8 and Boost to 1.61.

Issue #250
rakhimov added a commit that referenced this issue Jan 5, 2018
[skip ci]

Provide a link to the Cpp core guidelines website
instead of the github repository.

Issue #250
rakhimov added a commit that referenced this issue Jan 5, 2018
rakhimov added a commit that referenced this issue Jan 5, 2018
No need to declare undefined move constructors.
Only HouseEvent still needs the phony constructor due to NRVO.

- xml::StreamElement
- gui::test::SignalSpy

Issue #250
@rakhimov
Copy link
Owner Author

rakhimov commented Jan 5, 2018

clang 5.0 fails with libstdc++ std::variant: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=877838

@rakhimov
Copy link
Owner Author

rakhimov commented Jan 5, 2018

std::optional and std::variant are missing from macOS Xcode 9: https://forums.developer.apple.com/thread/79555

rakhimov added a commit that referenced this issue Jan 5, 2018
One major difference is how a string_view is converted into a string.
With boost::string_ref, there is to_string member function,
whereas std::string_view needs to be passed to std::string ctor.
The benefit is that <string_view> does not include <string>.

Issue #250
rakhimov added a commit that referenced this issue Jan 5, 2018
Unlike boost::string_ref,
std::string_view is hashable.

Issue #250
rakhimov added a commit that referenced this issue Jan 5, 2018
C++17 std::tuple supports implicit constructor.

Issue #250
rakhimov added a commit that referenced this issue Jan 5, 2018
rakhimov added a commit that referenced this issue Jan 5, 2018
Ideally, AppleClang 9.1 is needed for C++17,
so one has to wait till Travis upgrades the macOS toolchain.
Alternatively, clang is available from homebrew.

Issue #250
@rakhimov
Copy link
Owner Author

rakhimov commented Jan 5, 2018

<filesystem> is not yet available by default w/ GCC 7 or Clang 5.
Hopefully, it will be available in GCC 8 and Clang 6.

rakhimov added a commit that referenced this issue Jan 5, 2018
[skip appveyor]

Clang 5.0 bugs with libstdc++.

Issue #250
@rakhimov
Copy link
Owner Author

rakhimov commented Jan 5, 2018

Clang-format 5.0 gets confused with C++17 structured bindings:
https://reviews.llvm.org/D37132

rakhimov added a commit that referenced this issue Jan 5, 2018
std::variant has different API and guarantees than boost::variant:

- std::variant no allocation guarantee (corner case w/ exception)
- boost::apply_visitor -> std::visit
- boost::get<T>(variant*) -> std::get_if<T>(variant*)
- std::holds_alternative<T> for query
- Cannot store references in std::variant (use pointers instead)

Issue #250
@rakhimov rakhimov closed this as completed Jan 5, 2018
@rakhimov
Copy link
Owner Author

rakhimov commented Jan 6, 2018

Qt5 moc doesn't understand C++17 nested namespace definition.

rakhimov added a commit that referenced this issue Jan 6, 2018
rakhimov added a commit that referenced this issue Jan 6, 2018
rakhimov added a commit that referenced this issue Jan 6, 2018
[skip appveyor]

lupdate is broken with C++17.

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

No branches or pull requests

1 participant