0
I have the following structure within a program:
struct STR00034ST{
char C_O010XC14B, C_O020XC14B;
short S_0010XI15C;
float F_0010XI1D;
STR00034ST (char _C_O010XC14B, char _C_O020XC14B, short _S_0010XI15C, float _F_0010XI1D){
C_O010XC14B=_C_O010XC14B;
C_O020XC14B=_C_O020XC14B;
S_0010XI15C=_S_0010XI15C;
F_0010XI1D=_F_0010XI1D;
}
};
But whenever I compile it returns the following error: 'error: expected specifier-Qualifier-list before 'STR00034ST''
I’ve been researching and realized that I only found examples of struct constructor use within the C++ language and not in C. Therefore, it is impossible to use constructors inside a C struct?
Just your boot example that doesn’t boot anything. The rest seems right to me
– Jefferson Quesado