This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

结构体函数传递地址的问题



由于使用了DSP的两个SCI做485通信,程序一模一样,因此在程序中凡是涉及ScibRegs SciaRegs 的变量我想用传地址的形式,在函数调用时将地址传过去。void rxtongxun(struct SCI_REGS *scireg)

{

Uint16 m,i;
static Uint16 D3Flg = 0;

if (ScibRegs.SCIRXST.bit.RXERROR && *scireg.SCIRXST.bit.RXWAKE)//
{


报错:"rxtongxun.c", line 78: error: expression must have struct or union type

报错报的是右边那个,如果左边那个也改成右边指针形式的话会报两个错,如果右边指针改成变量名的话就不报错。

请教大家: 这是什么原因?