C++ in 2016
A short overview on what is to expect from C++ in 2016:
C++ in 2016
by Jens Weller
From the article:
Like in the previous years, a short outlook into the fresh year regarding C++...
June 16-21, Sofia, Bulgaria
September 13-19, Aurora, CO, USA
October 25, Pavia, Italy
November 6-8, Berlin, Germany
November 3-8, Kona, HI, USA
By Meeting C++ | Jan 22, 2016 06:58 AM | Tags: conferences community c++17 basics
A short overview on what is to expect from C++ in 2016:
C++ in 2016
by Jens Weller
From the article:
Like in the previous years, a short outlook into the fresh year regarding C++...
By Mantosh Kumar | Jan 17, 2016 10:54 PM | Tags: intermediate
How to write customizable framework which would work on "practically any type". This article is continuation of author previous post: "Overload resolution".
A customizable framework
by Andrzej Krzemieński
From the article:
We want to provide a function (or a set of overloaded functions) that would ‘do the right job’ for ‘practically any type’, or for ‘as many types as possible’. As an example of such ‘job’ consider std::hash: what we want to avoid is the situation, where you want to use some type X as a key in the standard hash-map, but you are refused because std::hash does not ‘work’ for X. In order to minimize the disappointment, the Standard Library makes sure std::hash works with any reasonable built-in or standard-library type. For all the other types, that the Standard Library cannot know in advance, it offers a way to ‘customize’ std::hash so that they can be made to work with hash-maps.
By Mantosh Kumar | Jan 17, 2016 09:38 PM | Tags: c++11 advanced
How to use C++11 threads library for setting various attributes related to thread affinity/hyper-threading.
C++11 threads, affinity and hyperthreading
by Eli Bendersky
From the article:
This post is not a tutorial on C++11 threads, but it uses them as the main threading mechanism to demonstrate its points. It starts with a basic example but then quickly veers off into the specialized area of thread affinities, hardware topologies and performance implications of hyperthreading. It does as much as feasible in portable C++, clearly marking the deviations into platform-specific calls for the really specialized stuff.
By Adrien Hamelin | Jan 11, 2016 08:23 AM | Tags: intermediate c++14
Nice use of modern C++:
Writing modern C++ servers using Wangle
by James Perry
From the article:
I mentioned in my previous post that I was able to build a prototype database engine within one day using Facebook’s Wangle so this post explains how I managed that. By the end of this post, you will be able to write a high-performance C++ server using Wangle. This post also serves as a tutorial which will be merged into Wangle’s README.md.
By Adrien Hamelin | Jan 6, 2016 07:56 AM | Tags: c++11 basics
Explications of the noexcept
keyword:
Modern C++ Features – keyword `noexcept`
by Arne Mertz
From the article:
I have written about handling exceptions some time ago, and about the levels of exception safety last week. What I have not touched yet are exception specifications. I will catch up on those with this post.
C++98 had the possibility to denote the types of exceptions that could be thrown from a given function by using
throw(<exception list>)
. In theory, the runtime had to check if any exception emitted by the function was indeed in that list or derived from one of the types in the list. If it wasn’t, the handlerstd::unexpected
would be called...
By Meeting C++ | Jan 6, 2016 06:56 AM | Tags: user group community
The monthly update of C++ User Group Meetings at Meeting C++:
C++ User Group Meetings in January 2016
by Jens Weller
From the article:
The monthly overview on upcoming C++ User Group meetings! There is a new C++ User Group in Iasi, Romania and a lot of C++ User Groups which are meeting in January!
Maybe you want to start a C++ User Group in 2016? Also feel free to contact me on the topic!
By Adrien Hamelin | Jan 4, 2016 09:01 AM | Tags: None
Quick A: they are the same
Recently on SO:
Quick Q: C++11 auto declaration with and without pointer declarator
The declarations are exactly equivalent.
auto
works (almost) the same as template type deduction. Putting the star explicitly makes the code a bit easier to read, and makes the programmer aware thatbar2
is a pointer.
By Adrien Hamelin | Jan 4, 2016 08:55 AM | Tags: c++14 advanced
An interesting article:
A flexible lexicographical comparator for C++ structs
by Björn Fahller
From the article:
We've all hand crafted comparison operators for structs with many members, and we've all cursed the tedium. It's all right for equality comparison, but lexicographical ordering relations is a different story when there are more than two members.
Hopefully all C++ developers have by now learned about the std::tie()-idiom.
struct S { int a; int b; int c; }; bool operator<(const S& lh, const S& rh) { return std::tie(lh.a, lh.b, lh.c) < std::tie(rh.a, rh.b, rh.c); }
By Adrien Hamelin | Jan 4, 2016 06:29 AM | Tags: basics
A nice introduction to C++ exceptions:
Levels of Exception Safety
by Arne Mertz
From the article:
Exceptions are part of C++. They are thrown by the standard library classes, and sometimes even if we are not really using the standard library. So, unless we are in a very restrictive environment like embedded programming and have exceptions disabled in the compiler, we need to be prepared and deal with the fact that exceptions simply can happen.
By Blog Staff | Jan 2, 2016 06:16 PM | Tags: None
A nice and short (5-minute read) entrepreneur's perspective about technology choices while starting a modern web company, with nice shout-outs to Folly, Proxygen, and Wangle:
Starting a tech startup with C++
by James Perry
From the article:
A lot of my peers think it is bizarre that I am building a cloud service with C++ and not with a dynamic language — such as Ruby or Python — that provides high productivity to ship quickly.
It started to question my own judgement to use C++ and I decided to research whether it is good idea or not.