Clang is now feature complete for C++14
llvm.org
llvm.org
They probably have good reasons, such as keeping the same ABI as long as possible, but it's sometimes very frustrating.
[1] http://gcc.gnu.org/onlinedocs/libstdc++/manual/status.html#s...
[1] http://llvm.org/viewvc/llvm-project?view=revision&revision=1...
edit: thanks misframer
One thing I really don't like about libc++ is that it doesn't support anything from TR1 - makes it needlessly difficult to use in existing code bases.
*much more common combination*
Why? no clue, no reason.
But Clang with libc++? There're reasons.The primary Clang user groups are Apple and FreeBSD communities. a.k.a. anti-GCC groups. Both of them really want to avoid any GCC stuff and are officially deprecating all the GCC stuff. Having dependency to GCC stuff is nonsense on these platforms. If common developers are sane enough, they' won't use libstdc++.
And other group is the Linux development. But I don't think there're really many developers who are using Clang for production on Linux. There's no big push from the platform, and also no big benefits. But there're many shortcomings for using Clang. It's not installed by default, not supported by platform, not tested much.
If there're some people want to adapt Clang on Linux even now, they won't hesitate to use libc++. And the others will just stays in good old GCC with libstdc++.
I think there are several benefits in using clang tools. You might find useful the Chandler Carruth's talk on Going Native on which he demoed some great tools that doesn't really have alternative on the gnu toolchain.
http://channel9.msdn.com/Events/GoingNative/2013/The-Care-an...
For me, the killer is typically optimization: e.g. for a CPU-intensive app I work on, gcc generates a binary that is twice as fast as what clang generates (this has been true for ages and across many compiler versions). I can live with slightly pokey compiles, but having my program take one week to execute instead of two is pretty compelling...
I think you meant to say anti-GPLv3 groups and you also forgot to include Linux kernel devs.
This has led to a few hours down the drain...
template<typename _Tp, typename _Alloc = std::allocator<_Tp> > class list : protected _List_base<_Tp, _Alloc> { ... size_type size() const { return std::distance(begin(), end()); }
(libc++ keeps a track of the size somewhere, but this in occurs a 4/8 byte overhead)
It's four goddamn bytes. Or eight if you really want more than 4 billion elements.
As long as you don't have millions of lists with a few elements each -- you can't presume that they are only used one way :)
Hell, you probably lose that much to padding somewhere anyways.
That may make 'splice' slower. See http://home.roadrunner.com/~hinnant/On_list_size.html (I think that could be solved by having list iterators carry a field pointing to their container, but haven't given it much thought. Corrections welcome)
Storing an index in the iterator would not be a solution either. That would mean updating the index in all the existing iterators when you insert an object in the list.
libc++ has the luxury of assuming c++11.
Also, linked lists are notoriously crap for cache coherency / processor pre-fetching and branch prediction by processors anyway, given that there's no guarantee where each node will be allocated - the only way to do that is pull them off a slab allocator or something, in which case you might as well use a vector or deque anyway...
I don't that tracking the size would be a big deal, if you think that doing that they wouldn't be a linked list any more, you could think it as a linked link wrapper.
In any case the complexity guarantees of all the other operations remain true so I don't think it is a big deal.
In C++ you are supposed to reuse standard abstractions; So you can - do your own std::list; (still have to copy iterators and everything into it;-) - do your own wrapper around std::list that exposes a weaker interface, - make your own list and everybody start to bitch that you are reinventing the wheel.
Anyone recommends a good book, or any other dense/complete material, on C++11/C++14? I barely got C++11, never really practiced, and I could use a good material to dive deep into it.
Also there is The tour of C++ (http://www.stroustrup.com/Tour.html) which offer a fresh start to the language.
But the one book I am waiting for is Effective C++ 11/14 which should coming up next year.
Likewise! And from your first link there is a sort of preview of Scott Meyers' upcoming book http://channel9.msdn.com/Events/GoingNative/2013/An-Effectiv...
The more technical videos on Channel 9 are terrific stuff, and hooray for download links! Kudos to Microsoft.
[1] http://channel9.msdn.com/Series/C9-Lectures-Stephan-T-Lavave...
[2] http://channel9.msdn.com/Series/C9-Lectures-Stephan-T-Lavave...
Also I forgot to mention C++ and Beyond (http://cppandbeyond.com/video-gallery/)
Either way, the better error messages in clang make it worth sticking to.
By Scott Meyers
git clone http://llvm.org/git/llvm.git
Thanks for the clarification :)
(The second-best is git, of course. :)
From 100100 to 194194 there are 194 of those kind of numbers (e.g 133133).
Even more if you count other symmetries as "significant", e.g 100001 or 123321
Uh oh, I think we may have run into... PHILOSOPHY!
Subversion is the equivalent of using paper tape to store your source code. It's centralized, bloody slow, and missing a number of features taken for granted in a system like Git.