[cfe-commits] r73082 - in /cfe/trunk: include/clang/Driver/Options.def lib/Driver/Tools.cpp test/Driver/clang_f_opts.c
Daniel Dunbar
daniel at zuster.org
Mon Jun 8 14:13:54 PDT 2009
Author: ddunbar
Date: Mon Jun 8 16:13:54 2009
New Revision: 73082
URL: http://llvm.org/viewvc/llvm-project?rev=73082&view=rev
Log:
PR4016: Forward -fno-show-source-location to clang.
Modified:
cfe/trunk/include/clang/Driver/Options.def
cfe/trunk/lib/Driver/Tools.cpp
cfe/trunk/test/Driver/clang_f_opts.c
Modified: cfe/trunk/include/clang/Driver/Options.def
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Driver/Options.def?rev=73082&r1=73081&r2=73082&view=diff
==============================================================================
--- cfe/trunk/include/clang/Driver/Options.def (original)
+++ cfe/trunk/include/clang/Driver/Options.def Mon Jun 8 16:13:54 2009
@@ -419,6 +419,7 @@
OPTION("-fno-math-errno", fno_math_errno, Flag, f_Group, INVALID, "", 0, 0, 0)
OPTION("-fno-pascal-strings", fno_pascal_strings, Flag, f_Group, INVALID, "", 0, 0, 0)
OPTION("-fno-show-column", fno_show_column, Flag, f_Group, INVALID, "", 0, 0, 0)
+OPTION("-fno-show-source-location", fno_show_source_location, Flag, f_Group, INVALID, "", 0, 0, 0)
OPTION("-fno-stack-protector", fno_stack_protector, Flag, clang_ignored_f_Group, INVALID, "", 0, 0, 0)
OPTION("-fno-strict-aliasing", fno_strict_aliasing, Flag, clang_ignored_f_Group, INVALID, "", 0, 0, 0)
OPTION("-fno-unit-at-a-time", fno_unit_at_a_time, Flag, f_Group, INVALID, "", 0, 0, 0)
@@ -446,6 +447,7 @@
OPTION("-fprofile-arcs", fprofile_arcs, Flag, f_Group, INVALID, "", 0, 0, 0)
OPTION("-fprofile-generate", fprofile_generate, Flag, f_Group, INVALID, "", 0, 0, 0)
OPTION("-framework", framework, Separate, INVALID, INVALID, "l", 0, 0, 0)
+OPTION("-fshow-source-location", fshow_source_location, Flag, f_Group, INVALID, "", 0, 0, 0)
OPTION("-fsigned-bitfields", fsigned_bitfields, Flag, f_Group, INVALID, "", 0, 0, 0)
OPTION("-fsigned-char", fsigned_char, Flag, f_Group, INVALID, "", 0, 0, 0)
OPTION("-fstack-protector", fstack_protector, Flag, clang_ignored_f_Group, INVALID, "", 0, 0, 0)
Modified: cfe/trunk/lib/Driver/Tools.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?rev=73082&r1=73081&r2=73082&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/Tools.cpp (original)
+++ cfe/trunk/lib/Driver/Tools.cpp Mon Jun 8 16:13:54 2009
@@ -550,8 +550,11 @@
options::OPT_fno_diagnostics_show_option))
CmdArgs.push_back("-fdiagnostics-show-option");
if (!Args.hasFlag(options::OPT_fcolor_diagnostics,
- options::OPT_fno_color_diagnostics))
+ options::OPT_fno_color_diagnostics))
CmdArgs.push_back("-fno-color-diagnostics");
+ if (!Args.hasFlag(options::OPT_fshow_source_location,
+ options::OPT_fno_show_source_location))
+ CmdArgs.push_back("-fno-show-source-location");
// -fdollars-in-identifiers default varies depending on platform and
// language; only pass if specified.
Modified: cfe/trunk/test/Driver/clang_f_opts.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/clang_f_opts.c?rev=73082&r1=73081&r2=73082&view=diff
==============================================================================
--- cfe/trunk/test/Driver/clang_f_opts.c (original)
+++ cfe/trunk/test/Driver/clang_f_opts.c Mon Jun 8 16:13:54 2009
@@ -2,9 +2,10 @@
// RUN: grep -F '"-fblocks"' %t &&
// RUN: grep -F '"--fmath-errno=1"' %t &&
// RUN: grep -F '"-fpascal-strings"' %t &&
-// RUN: clang -### -S -x c /dev/null -fblocks -fbuiltin -fmath-errno -fcommon -fpascal-strings -fno-blocks -fno-builtin -fno-math-errno -fno-common -fno-pascal-strings %s 2> %t &&
+// RUN: clang -### -S -x c /dev/null -fblocks -fbuiltin -fmath-errno -fcommon -fpascal-strings -fno-blocks -fno-builtin -fno-math-errno -fno-common -fno-pascal-strings -fno-show-source-location %s 2> %t &&
// RUN: grep -F '"-fblocks=0"' %t &&
// RUN: grep -F '"-fbuiltin=0"' %t &&
// RUN: grep -F '"-fno-common"' %t &&
// RUN: grep -F '"--fmath-errno=0"' %t &&
+// RUN: grep -F '"-fno-show-source-location"' %t &&
// RUN: true
More information about the cfe-commits
mailing list