由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - 程序怎么不认识class, namespace等identifier呀?
相关主题
operator overloading (C++)C++ 无效语句?
【求助】为什么类里面不能初始化vector的大小? (转载)What is wrong in this array declaration.
template questionmetaprogramming
c++ size_t 一问Question about a C++ compilation error on Visual Studio 2005
三个C syntax 弱问题From C++ to C
a question abou dll, 3x!!C++ syntax question
来几个C++测试题int F::*x = &F::x是什么意思?
[合集] 编程的习惯问题Linq不是syntactic sugar
相关话题的讨论汇总
话题: identifier话题: class话题: namespace话题: 认识话题: 程序
进入Programming版参与讨论
1 (共1页)
f********f
发帖数: 475
1
第一次用Visual Studio .net 2005, 需要将一个算法程序从C变成C++. 其实就是很小
的改动, 原来是两个global的functions, 现在我将他们放到一个class里变成两个
static functins. 但是编译的时候告诉我
error C2061: syntax error : identifier 'class'
好象是不认识class这个identifier. 试了一下namespace, 也不认识, 怎么回事呢? 谢谢!
f********f
发帖数: 475
2
faint, I know it. The code file extension should be .cpp, cannot be .c

谢谢!

【在 f********f 的大作中提到】
: 第一次用Visual Studio .net 2005, 需要将一个算法程序从C变成C++. 其实就是很小
: 的改动, 原来是两个global的functions, 现在我将他们放到一个class里变成两个
: static functins. 但是编译的时候告诉我
: error C2061: syntax error : identifier 'class'
: 好象是不认识class这个identifier. 试了一下namespace, 也不认识, 怎么回事呢? 谢谢!

1 (共1页)
进入Programming版参与讨论
相关主题
Linq不是syntactic sugar三个C syntax 弱问题
Python 缩进的syntaxa question abou dll, 3x!!
原来Haskell里面的quasiquoting是来自lisp的来几个C++测试题
JAVA的确是要取代C++的[合集] 编程的习惯问题
operator overloading (C++)C++ 无效语句?
【求助】为什么类里面不能初始化vector的大小? (转载)What is wrong in this array declaration.
template questionmetaprogramming
c++ size_t 一问Question about a C++ compilation error on Visual Studio 2005
相关话题的讨论汇总
话题: identifier话题: class话题: namespace话题: 认识话题: 程序