From Jason Turner
Watch on YouTube

Summary

This episode explores C++14's variable templates, a feature that Jason admits he didn't fully appreciate until years after its introduction. He demonstrates how variable templates work by creating a templated pi constant with different numeric type specializations. Jason then shows more powerful applications including specialization patterns similar to class templates, implementing type traits like is_same, and using variable templates to generate typed lambda functions.

Resources

Tags