Hello everybody!
Recently while i was experimenting with some code written in c++ i noticed something that confused me a bit. In that code i had to deal with 2 structs :
Code:
struct date
{
string day;
int month;
int dday;
int year; };
and the other struct
Code:
struct note
{
date d;
string notice; };
I noticed that when i was passing in a function i built, an instance of note struct as a pointer parameter my program kept crashing continuously, although compiler wasn't complaining. To make myself clear :
Has anyone got an idea why the pointer parameter and the arrow
caused that problem? Looking forward to reading your ideas and thoughts...Thank you in advance for your time...
Thank you very much for your reply Lindley, but i found what caused the whole problem. The . operator precedes the -> operator in expressions so i had to write my code like this:
Bookmarks