I'm trying to figure out how to create a new class and access it (sorry if that's not worded right) when coding in VS Code, but I keep getting the error shown below:
main.obj : error LNK2019: unresolved external symbol "public: __thiscall Burrito::Burrito(void)" (??0Burrito@@QAE@XZ) referenced in function _main
How can I create a new class for C++ and access it in VS Code?
all three files are shown here
Also, here are my code files as text:
// main.cpp
#include <iostream>
#include "Burrito.h"
using namespace std;
int main()
{
Burrito bo;
return 0;
}
// Burrito.h
#ifndef BURRITO_H
#define BURRITO_H
#include <iostream>
#include <string>
using namespace std;
class Burrito
{
public:
Burrito();
};
#endif
// Burrito.cpp
#include "Burrito.h"
#include <iostream>
using namespace std;
Burrito::Burrito()
{
cout << "hi people" << endl;
}