
Sergey Larin
PVS-Studio
Log in to watch the video
LoginNobody likes writing a lot of if else if code. In many languages, pattern matching exists to solve this problem.
Unfortunately, C++ only has it for std::variant via std::visit.
We'll discuss how to implement your own simple pattern matching solution using the example of working with AST nodes.

PVS-Studio