我正在尝试在包含注释的JS文件上运行CPP.我想保留评论,所以我使用的是-C参数gcc -E -P,但是GCC或CPP会添加额外的评论.以下是如何重现:
? cpp-test ls
? cpp-test touch empty
? cpp-test gcc -E -P -x assembler-with-cpp -C empty -o empty.out
? cpp-test cat empty.out
/* Copyright (C) 1991-2013 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */
/* This header is separate from features.h so that the compiler can
include it implicitly at the start of every compilation. It must
not itself include <features.h> or any other header that includes
<features.h> because the implicit include comes before any feature
test macros that may be defined in a source file before it first
explicitly includes a system header. GCC knows the name of this
header in order to preinclude it. */
/* We do support the IEC 559 math functionality, real and complex. */
/* wchar_t uses ISO/IEC 10646 (2nd ed., published 2011-03-15) /
Unicode 6.0. */
/* We do not support C11 <threads.h>. */
? cpp-test
Run Code Online (Sandbox Code Playgroud)
我如何告诉GCC/CPP不生成这些评论?
| 归档时间: |
|
| 查看次数: |
921 次 |
| 最近记录: |