From Jason Turner
Watch on YouTube

Summary

This episode explains Argument Dependent Lookup (ADL), a C++ language feature that enables calling functions without fully qualifying their namespace when the function takes arguments from that namespace. Jason demonstrates how this mechanism allows us to call functions like std::begin() without the std:: prefix when passing standard library containers as arguments. He also shows how ADL searches through namespaces associated with argument types, which can sometimes lead to unexpected function resolution.

Resources

Tags