错误错误 C2872:"布尔值":kinect.h 的不明确符号
Error error C2872: 'boolean': ambiguous symbol for kinect.h
VS19更新到16.3.8后,我无法构建我的项目,我收到以下错误:
C:Program FilesMicrosoft SDKsKinectv2.0_1409incKinect.h(8574,28): error C2872: 'boolean': ambiguous symbol
C:Program Files (x86)Windows Kits10Include10.0.18362.0sharedrpcndr.h(193,23): message : could be 'unsigned char boolean'
C:Program Files (x86)Microsoft Visual Studio2019CommunityVCToolsMSVC14.23.28105includeconcepts(213,9): message : or 'bool std::boolean'
我试过检查kinect.h标头,但我没有修改它的权限,我不想处理一些我不熟悉的东西。在更新(VS19 16.0.0(之前,它一直在工作。我也尝试过清理、重新启动,并仔细检查是否有任何正在使用的命名空间,但错误仍然存在。
基于错误:
概念文件包括以下行
#define _STL_BOOLEAN_CONCEPT boolean
rpcndr.h
typedef unsigned char boolean;
然后kinect.h
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsInertial(
/* [annotation][out][retval] */
_Out_ boolean *value) = 0;
根据这些评论,通过将C++语言标准设置为C++17,我成功地构建了我的项目。
相关文章:
- C++ 编译器错误:P1LinkedList.cpp:145:错误:重载的"to_string(int&)"调用不明确
- gcc出现不明确的模板实例化错误
- "byte":使用Crypto++和Windows SDK时出现不明确的符号错误
- 使用 std::iterator_traits<> 时编译时错误不明确
- 在类Bat代码中,这给了我错误:重载的"Bat()"的调用是不明确的Bat(;)
- 错误错误 C2872:"布尔值":kinect.h 的不明确符号
- C++打印模板容器错误(错误:"运算符<<"的不明确重载)理解?
- 错误:使用复制和交换习惯用法的交换函数中"operator="的重载不明确
- 不明确的错误重载运算符<<QdataStream 子类和个人类
- 模板上下文中的"不明确的基类"错误
- C++ 模板不明确错误
- 为什么调用不明确的 ctor 时没有编译时错误?
- G++ 错误:重载的"abs(无符号 int)"的调用不明确
- 提升错误:"运算符=="的重载不明确
- Qt 中的错误不明确
- C++ 继承错误:不明确的错误
- 超类运算符()错误-不明确
- 符号错误不明确
- 构造函数中的分段错误不明确
- 错误:不明确的默认类型转换(c++)