Intro to Template Metaprogramming - Template Metaprogramming in C++ - E1

preview_player
Показать описание
This is the first episode of a new Bits of Q series on Template Metaprogramming in C++.

-- TIMESTAMPS --
00:00 - Introduction
00:45 - What is Metaprogramming?
02:11 - Compiler Explorer
03:04 - Template Functions
04:18 - Type Traits
05:54 - Template Specialization crash course
09:28 - Writing Type Traits
14:05 - Writing a MetaFunction
15:38 - Summary

Related materials:
Thorough introduction to templates: Arthur O'Dwyer CppCon 2016: Template Normal Programming

Outro music by lesfm from pixabay.
Thanks to Willem Sonke and Bram Custers for reviewing the first draft of this episode.

If you have any questions or feedback, just leave a comment below.

See you next time!
Рекомендации по теме
Комментарии
Автор

there really is some small channel out there, unoticed by many but offers gold knowledgeable content, this channel is one of those, still at the first episodes and I already love what I learned.

SheelByTorn
Автор

I'm glad that I've found this channel.

rivendzi
Автор

10:53 ok this absolutely blew my mind!

acho
Автор

Such good grasp on content. Wow. Thanks for the videos.

abhi-
Автор

Thank you! Your telling is blazingly clear!

Автор

Great c++ metaprogramming tutorial. I so glad I finally found it

hengtan
Автор

Thank you for all your hard work! Your channel is super helpful!

dominikwyss
Автор

wow! you're awesome or what! Just discovered you. Thank you great video!

thestarinthesky_
Автор

your knownledge is helpul so i'm subscribe your channel, keep spirit and Don't get tired of helping people😊😉

helloworld
Автор

Audio quality is not good but nvm content is great on your channel. Looking forward for more content on C++ from you. Gonna recommend to others also.

lgbtkeyboard
Автор

strip_pointer can also be implemented by recursion!

template<typename T>
struct strip_pointer{
using type = T;
};

template<typename T>
struct strip_pointer<T*>{
using type = typename strip_pointer<T>::type;
};

abhi-
Автор

Do you have a video covering concepts in C++20? Great video btw

carslex
Автор

so what about double pointers? how would one treat that?

maryguty
Автор

Thanks for the video.

At 15:33 line 26, only works for c++20. For older version we have to use:

using T_without_pointer = typename strip_pointer<T>::type;

Otherwise I get the error: need 'typename' before 'strip_pointer<T>::type' because 'strip_pointer<T>' is a dependent scope

Could someone explain why this is the case? Thanks

muhammadwaleedbinkhalid
Автор

Oh my goodness, the audio quality.... Please put your videos in an editor like Davinci Resolve or Shotcut or something and play with some EQ, Compression, or at least hit the normalize button. Also, do not point the mic at your throat, we can hear every single drop of saliva.

ChristopherPisz
Автор

next time try to speak more clearly its difficult to understand you

carnaqe
join shbcf.ru