/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

studiofreya.org
| | www.foonathan.net

Just like regular function parameters, template parameters can also have default parameters. For class templates, this behaves mostly just like default function arguments: if you pass fewer template arguments than required, default template arguments are used to fill the remaining places. However, for function templates, it gets more complicated as template parameters for functions can be deduced by the normal function arguments. This leads to some interesting side-effects. In particular, default argumen...
2.2 parsecs

Travel
| |
| | www.cppstories.com

For C++17 everyone wanted to have concepts, and as you know, we didn't get them. But does it mean C++17 doesn't improve templates/template meta-programming? Far from that! In my opinion, we get excellent features. Read more for details. Intro Do you work a lot with templates and meta-programming? With C++17 we get a few nice improvements: some are quite small, but also there are notable features as well!
2.5 parsecs

Travel
| |
| | www.bfilipek.com

Variadic Templates from C++11 is probably not a feature that you use on a daily basis. But recently, I've come across one refactoring example where I've decided to give a try and apply variadics. Intro When I was doing some work in some old UI code I've noticed several similar lines of code that looked like that:
2.0 parsecs

Travel
| |
| | nora.codes

[AI summary] The article explains the concept of 'unsafe' in Rust, clarifying that it allows specific low-level operations while maintaining overall memory safety through the language's type system and safe abstractions.
17.6 parsecs

Travel
|