aboutsummaryrefslogtreecommitdiff
path: root/include/clang/Frontend/CompilerInvocation.h
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-11-29 20:58:50 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-11-29 20:58:50 +0000
commite03245246acbec5c46e93b68ec6942ce42b9e256 (patch)
treecb4d0ae874c7b690a8d2ee2bf30a7b2ba424719b /include/clang/Frontend/CompilerInvocation.h
parent4cbe3b64be7b1b312e4e555e8c93ef8e5bd3a820 (diff)
Change CompilerInvocation::CreateFromArgs to report errors using a proper diagnostic engine.
- Clients that care about having the diagnostics output honor the user-controllable diagnostic options can buffer the diagnostics and issue them later. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90092 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Frontend/CompilerInvocation.h')
-rw-r--r--include/clang/Frontend/CompilerInvocation.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/clang/Frontend/CompilerInvocation.h b/include/clang/Frontend/CompilerInvocation.h
index 76863d4ae0..e7c51aabba 100644
--- a/include/clang/Frontend/CompilerInvocation.h
+++ b/include/clang/Frontend/CompilerInvocation.h
@@ -31,6 +31,8 @@ namespace llvm {
namespace clang {
+class Diagnostic;
+
/// CompilerInvocation - Helper class for holding the data necessary to invoke
/// the compiler.
///
@@ -77,8 +79,6 @@ public:
/// CreateFromArgs - Create a compiler invocation from a list of input
/// options.
///
- /// FIXME: Documenting error behavior.
- ///
/// \param Res [out] - The resulting invocation.
/// \param ArgBegin - The first element in the argument vector.
/// \param ArgEnd - The last element in the argument vector.
@@ -86,9 +86,11 @@ public:
/// compiler path.
/// \param MainAddr - The address of main (or some other function in the main
/// executable), for finding the builtin compiler path.
+ /// \param Diags - The diagnostic engine to use for errors.
static void CreateFromArgs(CompilerInvocation &Res, const char **ArgBegin,
const char **ArgEnd, const char *Argv0,
- void *MainAddr);
+ void *MainAddr,
+ Diagnostic &Diags);
/// toArgs - Convert the CompilerInvocation to a list of strings suitable for
/// passing to CreateFromArgs.