【问题标题】:redeclaration of C++ built-in type 'wchar_t' windows 10 glut cpp重新声明 C++ 内置类型'wchar_t' windows 10 glut cpp
【发布时间】:2017-06-30 19:07:41
【问题描述】:

我正在尝试在 C++ 中运行一些 Glut 应用程序,但我的代码块给了我一个错误

redeclaration of C++ built-in type 'wchar_t'

它指向 glut.h 文件的第 50 行:

typedef unsigned short wchar_t;

我已经下载了这个程序并将所有 src 文件移到了新的代码块项目中

http://www.mindcontrol.org/~hplus/graphics/fire-particles.html

如何解决?

【问题讨论】:

标签: c++ glut


【解决方案1】:

我遇到了理智的问题。这就是我解决问题的方法。

#include<windows.h>
#include<bits/stdc++.h>
#include <GL/glut.h>

windows.h> 应首先添加,否则会显示错误。我希望它能解决问题 谢谢

【讨论】:

  • 这是 1 年前问过的,伙计;)我通过在 Windows XP 上编译解决了这个问题。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2013-04-04
  • 2018-06-29
  • 1970-01-01
  • 1970-01-01
  • 2018-11-29
  • 1970-01-01
  • 2019-09-30
相关资源
最近更新 更多