Eclipse C 编译器无法识别 // 行内注释
eclipse C compiler does not recognize // in line comments
好的,这就是问题所在:我使用 yoxos 使我的 eclipse 保持最新:前几天我升级到 Mars .2 我的 C 编译器(GCC 工具链)停止接受 '//' 作为注释行,我检查了其他没有错误的项目,现在有同样的错误:
描述......................资源..路径................................ ..位置...类型
'/' 标记前的预期表达式 demo.c /demo1/Host 第 98 行 C/C++ 问题
(93) /* STOP FLYING! */
(94)
(95) printf("\n END OF THE LINE******************************** %4d \n", count );
(96) PLatLon( dlat, dlon );
(97) /* print"</body></html>"; */
(98) // now return
(99) return(1);}
我在某个地方有一个怪异的开关 flipped/set 出错了?
这是我的控制台:
gcc
-I"/mnt/MyData/home/harrison/NexGen/Code-Base/NAV/Server/demo1/NAV_Includes"
-O0 -g3 -Wall -c -fPIC -lm -fmessage-length=0 -ansi -fPIC -MMD -MP -MF"Host/demo.d" -MT"Host/demo.o" -o "Host/demo.o" "../Host/demo.c
- 列表项:Project --> Properties --> C/C++ Build --> Settings 找到 Tool Settings 选项卡并更改 GCC C Compiler dialect --> Language Standard。你需要 c99.
- 列表项:Project --> Properties --> C/C++ Build --> Settings find the Tool Settings tab -> Miscellaneous uncheck Support ANSI programs
现在我的 // 错误消失了!
好的,这就是问题所在:我使用 yoxos 使我的 eclipse 保持最新:前几天我升级到 Mars .2 我的 C 编译器(GCC 工具链)停止接受 '//' 作为注释行,我检查了其他没有错误的项目,现在有同样的错误:
描述......................资源..路径................................ ..位置...类型
'/' 标记前的预期表达式 demo.c /demo1/Host 第 98 行 C/C++ 问题
(93) /* STOP FLYING! */
(94)
(95) printf("\n END OF THE LINE******************************** %4d \n", count );
(96) PLatLon( dlat, dlon );
(97) /* print"</body></html>"; */
(98) // now return
(99) return(1);}
我在某个地方有一个怪异的开关 flipped/set 出错了?
这是我的控制台:
gcc -I"/mnt/MyData/home/harrison/NexGen/Code-Base/NAV/Server/demo1/NAV_Includes" -O0 -g3 -Wall -c -fPIC -lm -fmessage-length=0 -ansi -fPIC -MMD -MP -MF"Host/demo.d" -MT"Host/demo.o" -o "Host/demo.o" "../Host/demo.c
- 列表项:Project --> Properties --> C/C++ Build --> Settings 找到 Tool Settings 选项卡并更改 GCC C Compiler dialect --> Language Standard。你需要 c99.
- 列表项:Project --> Properties --> C/C++ Build --> Settings find the Tool Settings tab -> Miscellaneous uncheck Support ANSI programs
现在我的 // 错误消失了!