This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

struct and pointer

hi,
i need a solution on how to read a struct which includes serveral types of vars with a pointer of type char.

example:

 struct test
 {
  char a;
  int  b;
  int  c;
  char d;
 };

struct test s_test;
char *p_test;


p_test = &s_test.a;
...

the compiler display error like pointer not the type of struct.