错误:预期')'之前'?' 代币

0 c compiler-errors syntax-error

所以我收到这个错误,即使我正在编译的代码没有'?' 一点都不 我使用gcc作为我的编译器和链接器.有关为何发生这种情况的任何提示?

此外,当我从函数名称中删除'l'时,错误消失了.我糊涂了.

显示错误的代码段:

unsigned long htonl(unsigned long ll) //Says error is on this line
{
    UDWord x;
    UDWord y;

    x.ul = ll;
    y.uc[0] = x.uc[3];
    y.uc[1] = x.uc[2];
    y.uc[2] = x.uc[1];
    y.uc[3] = x.uc[0];
    return y.ul;
}
Run Code Online (Sandbox Code Playgroud)

DrC*_*DrC 5

htonl有时被定义为gcc的标准包含文件中的宏.使用其他名称.