gpt4 book ai didi

c++ - 错误 : expected unqualified-id befo re '{' token

转载 作者:太空宇宙 更新时间:2023-11-04 07:32:05 25 4
gpt4 key购买 nike

我在下面的代码片段中收到error: expected unqualified-id before '{' token。有人可以清楚哪里出了问题吗?这是来自 opencv2.1 包的代码片段。

当我使用 stasm 包中的 make 文件构建 stasm 包时,我得到了这个。

/* Runtime assertion macro */
#define CV_ASSERT( Condition ) \
{ \
if( !(Condition) ) \

CV_ERROR( CV_StsInternal, "Assertion: " #Condition " failed" ); \
}

最佳答案

之间有一条额外的线:

    if( !(Condition) )                                                  \

CV_ERROR( CV_StsInternal, "Assertion: " #Condition " failed" ); \

那不应该在那里。应该是

    if( !(Condition) )                                                  \
CV_ERROR( CV_StsInternal, "Assertion: " #Condition " failed" ); \

    if( !(Condition) )                                                  \
\
CV_ERROR( CV_StsInternal, "Assertion: " #Condition " failed" ); \

关于c++ - 错误 : expected unqualified-id befo re '{' token,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12839783/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com