/explore

Click through on any links that interest you or select the planets on the right to continue exploring the Outer Web.
You are here

www.think-cell.com
| | www.foonathan.net

The size of std::array is known at compile-time given the type. Yet it only provides a regular .size() member function: template struct array { constexpr std::size_t size() const { return N; } }; This is annoying if you're writing generic code that expects some sort of compile-time sized range.
0.1 parsecs

Travel
| |
| | rodusek.com

Getting the name of a type in C++ is a hassle. For something that should be trivially known by the compiler at compile-time, the closest thing we have to getting the type in a cross-platform way is to use std::type_info::name which is neither at compile-time, nor is it guaranteed to be human-readable. In fact, both GCC and Clang actually return the compiler's mangled name rather than the human-readable name we are used to. Let's try to make something better using the modern utilities from c++17 and a little creative problem solving!
4.2 parsecs

Travel
| |
| | eyakubovich.github.io

In the previous post, we developed a logarithmic depth accumulate() function that can be used to emulate a for-loop. In this post, we'll look at how to construct a function that emulates a while-loop with the recursive depth of O(lg(n)) where n is the number of iterations of the while-loop....
3.9 parsecs

Travel
| |
| | www.jessesquires.com

If you have attempted to adopt Swift Concurrency in your codebase, you have certainly needed to address dozens - likely, hundreds - of warnings and errors. S...
28.8 parsecs

Travel
|