From df35d7f1916140bfed5ab0bad2d5e2bc62c667e5 Mon Sep 17 00:00:00 2001 From: Daniel Dunbar Date: Wed, 1 Jul 2009 20:30:52 +0000 Subject: [PATCH] Driver: Mark some Compilation members const. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@74636 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/clang/Driver/Compilation.h | 7 ++++--- lib/Driver/Compilation.cpp | 4 ++-- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/include/clang/Driver/Compilation.h b/include/clang/Driver/Compilation.h index 3ec221f41d..6414ef1369 100644 --- a/include/clang/Driver/Compilation.h +++ b/include/clang/Driver/Compilation.h @@ -32,10 +32,10 @@ namespace driver { /// invocation. class Compilation { /// The driver we were created by. - Driver &TheDriver; + const Driver &TheDriver; /// The default tool chain. - ToolChain &DefaultToolChain; + const ToolChain &DefaultToolChain; /// The original (untranslated) input argument list. InputArgList *Args; @@ -56,7 +56,8 @@ class Compilation { ArgStringList ResultFiles; public: - Compilation(Driver &D, ToolChain &DefaultToolChain, InputArgList *Args); + Compilation(const Driver &D, const ToolChain &DefaultToolChain, + InputArgList *Args); ~Compilation(); const Driver &getDriver() const { return TheDriver; } diff --git a/lib/Driver/Compilation.cpp b/lib/Driver/Compilation.cpp index d7901a69e0..7e29b67769 100644 --- a/lib/Driver/Compilation.cpp +++ b/lib/Driver/Compilation.cpp @@ -21,8 +21,8 @@ #include using namespace clang::driver; -Compilation::Compilation(Driver &D, - ToolChain &_DefaultToolChain, +Compilation::Compilation(const Driver &D, + const ToolChain &_DefaultToolChain, InputArgList *_Args) : TheDriver(D), DefaultToolChain(_DefaultToolChain), Args(_Args) { } -- 2.40.0