static_assert: Better template error messages—Michael Price

Save to:
Instapaper Pocket Readability

This article could be subtitled, and ends with, "Why we need Concepts."

Here's a quick take on how far you can get with just <type_traits> and static_assert, and why you might want to do that.

static_assert: Better template error messages

by Michael Price

From the article:

Templates are one of the most powerful features of C++, and provide the language with a serious advantage over many of its brethren.  But templates have serious drawbacks as well, one of which is the incredibly verbose and dense error messages that are provided should you fail to provide the right kind of parameter to a templated entity.

Add a Comment

Comments are closed.

Comments (0)

There are currently no comments on this entry.