文件名称:to_c_style_comment.tar
介绍说明--下载内容均来自于网络,请自行研究使用
将C++的单行注释改成C语言的注释.
在Windows 下用VC2005环境写程序的时候, 有C语言写的程序, 但是用了C++的注释, 也能成功编译连接运行. 但发现也有很多编译器不支持C++的单行注释. 又不想手机地改所有的代码. 所以写了一个程序来自动将C++的单行注释替换成C语言的注释格式.
压缩包中有两个文件. 其中 to_c_style_comment.c 中的我程序文件.
cpptest.c 只是一个测试文件. 是一个包含C++单行注释的c源程序, 仅供测试用.
编译方法:
gcc -o to_c_style_comment to_c_style_comment.c
测试方法:
./to_c_style_comment cpptest.c
或
./to_c_style_comment cpptest.c outputfile
-This program is to convert C++ one-line comment into a C language style comment. Under Windows, I was coding under the VC2005 environmental in C , but I inserted so many C++ one-line comments in my source code, (It works under such environment). But I found that there are many compilers does not support C++, a single line comment now. And I don t want to correct my code by hand, so wrote a program replace the C++ one-line comments with C-style comments. The compressed package consists with two files: to_c_style_comment.c is my program files. cpptest.c just a test file.( for test purposes only).
gcc-o to_c_style_comment to_c_style_comment.c test method:./to_c_style_comment cpptest.c or./to_c_style_comment cpptest.c outputfile
在Windows 下用VC2005环境写程序的时候, 有C语言写的程序, 但是用了C++的注释, 也能成功编译连接运行. 但发现也有很多编译器不支持C++的单行注释. 又不想手机地改所有的代码. 所以写了一个程序来自动将C++的单行注释替换成C语言的注释格式.
压缩包中有两个文件. 其中 to_c_style_comment.c 中的我程序文件.
cpptest.c 只是一个测试文件. 是一个包含C++单行注释的c源程序, 仅供测试用.
编译方法:
gcc -o to_c_style_comment to_c_style_comment.c
测试方法:
./to_c_style_comment cpptest.c
或
./to_c_style_comment cpptest.c outputfile
-This program is to convert C++ one-line comment into a C language style comment. Under Windows, I was coding under the VC2005 environmental in C , but I inserted so many C++ one-line comments in my source code, (It works under such environment). But I found that there are many compilers does not support C++, a single line comment now. And I don t want to correct my code by hand, so wrote a program replace the C++ one-line comments with C-style comments. The compressed package consists with two files: to_c_style_comment.c is my program files. cpptest.c just a test file.( for test purposes only).
gcc-o to_c_style_comment to_c_style_comment.c test method:./to_c_style_comment cpptest.c or./to_c_style_comment cpptest.c outputfile
(系统自动生成,下载前可以参看下载内容)
下载文件列表
to_c_style_comment.tar