I'm very confused as to what this error message means as I've defined Point as a simple struct that holds a char and an int value. The code effectively broke for me when I attempted to change from using a 2D vector of chars to a 2D vector of Points. Google has unfortunately not been my friend in this endeavor.
i guess grid is a 2d char array. so grid[i][j] is a char.
point is a struct of char and int.
point and char are 2 different datatypes, so you can't save a point as char. i guess you just want to save the char value of the point struct, so use "." to get the char and then save it in grid[i][j].
Darkmaster it is my understanding that I have defined the 2D vector as a vector of a vector that holds the type Point. The 2D vector, which I've named grid, should be of the correct type to accept the Point type.
MiiNiPaa I looked up how to clean my project, and I rebuilt it from scratch. Unfortunately, the error persists.
MiiNiPaa was right and my IDE totally lied to me. The issue was that Code::Blocks was failing to clean a single object file and overwrite it during subsequent build attempts. The object file just happened to be the one holding the grid definition. It appears that particular object file was last modified two days ago. That is pretty much the time I changed the grid definition to another type. I became suspicious when MiiNiPaa's single file example compiled and a brand new project with identical code also compiled. I took a quick look in the source folder itself, and I could see that one file was being left behind in clean/build cycles. I manually deleted it, and the next build completed successfully.
I would like to thank you all very much for your time, solutions, and code suggestions. It was extremely frustrating as hours spent looking for a bug in the code was in vain as the source code itself wasn't bugged. I was unaware of the clean function beforehand, and once I became aware of its existence/function that put me on the right track. I also learned to never trust a button fully does what it advertises.
MiiNiPaa's code may compile, but it won't work. As Darkmaster and I both pointed out previously, your vectors are empty. You can't store something into grid[i][j] when i or j are greater than the number of entries in the respective vector (zero). You will get a run time exception.