News for hackers. Stuff that matters.
Re:Why Type Systems Matter by gumby on Friday August 18, 2017 @09:52PM (#15051168)
> Most of the time I'd recommend the new type-safe union std::variant

Neither g++ 7 nor Clang/LLVM 4.0.1 support std::variant yet :-(. We started a new (blank buffer) codebase earlier this year and decided to use C++17 as the implementation language, which has exposed us to the gaps...which are surprisingly few! But sadly this is one of them.

Re:Why Type Systems Matter by shakna on Saturday August 19, 2017 @01:00AM (#15051765)
> Neither g++ 7

Eh? I've been using it a hell of a lot!

std::variant is listed on GCC 7's page [0], and I know that is there in at least 7.1

I don't use clang much, but they list it as supported [1], and I believe the patch [2] landed in 5.0

[0] https://gcc.gnu.org/gcc-7/changes.html

[1] https://libcxx.llvm.org/cxx1z_status.html

[2] https://reviews.llvm.org/rL288547

Re:Why Type Systems Matter by gumby on Saturday August 19, 2017 @11:40AM (#15053968)
Hmm, have to check include paths again!
Re:Why Type Systems Matter by shakna on Sunday August 20, 2017 @03:53PM (#15059960)
So I glanced over this, and found that std::variant is in libc++, as you would expect, but in some cases, when you get a nice modern compiler, you might not end up with it linked to a nice modern stdlib.

So maybe some sort of mis-match got in your way.

Anyways, here's hoping you get to use C++17 in its full glory!