VS Code C++: Undefined reference to functions defined in another .cpp file
Summary The issue of undefined references to functions defined in another .cpp file in a C++ project using VS Code and g++ (MSYS2) arises due to the linker not being able to find the definitions of these functions. This occurs because the compiler is only compiling the main.cpp file and not including the example.cpp file … Read more