summaryrefslogtreecommitdiffstats
path: root/Source/cmGeneratorExpression.h
diff options
context:
space:
mode:
authorKitware Robot <kwrobot@kitware.com>2016-05-16 14:34:04 (GMT)
committerBrad King <brad.king@kitware.com>2016-05-16 20:05:19 (GMT)
commitd9fd2f5402eeaa345691313658e02b51038f570b (patch)
treedca71b9a7e267f4c6300da3eb770415381726785 /Source/cmGeneratorExpression.h
parent82df6deaafb36cbbfd450202bb20b320f637751a (diff)
downloadCMake-d9fd2f5402eeaa345691313658e02b51038f570b.zip
CMake-d9fd2f5402eeaa345691313658e02b51038f570b.tar.gz
CMake-d9fd2f5402eeaa345691313658e02b51038f570b.tar.bz2
Revise C++ coding style using clang-format
Run the `Utilities/Scripts/clang-format.bash` script to update all our C++ code to a new style defined by `.clang-format`. Use `clang-format` version 3.8. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit.
Diffstat (limited to 'Source/cmGeneratorExpression.h')
-rw-r--r--Source/cmGeneratorExpression.h71
1 files changed, 37 insertions, 34 deletions
diff --git a/Source/cmGeneratorExpression.h b/Source/cmGeneratorExpression.h
index 001f2df..71fbba3 100644
--- a/Source/cmGeneratorExpression.h
+++ b/Source/cmGeneratorExpression.h
@@ -44,34 +44,36 @@ class cmGeneratorExpression
public:
/** Construct. */
cmGeneratorExpression(
- cmListFileBacktrace const& backtrace = cmListFileBacktrace());
+ cmListFileBacktrace const& backtrace = cmListFileBacktrace());
~cmGeneratorExpression();
cmsys::auto_ptr<cmCompiledGeneratorExpression> Parse(
- std::string const& input);
+ std::string const& input);
cmsys::auto_ptr<cmCompiledGeneratorExpression> Parse(const char* input);
- enum PreprocessContext {
+ enum PreprocessContext
+ {
StripAllGeneratorExpressions,
BuildInterface,
InstallInterface
};
- static std::string Preprocess(const std::string &input,
+ static std::string Preprocess(const std::string& input,
PreprocessContext context,
bool resolveRelative = false);
- static void Split(const std::string &input,
- std::vector<std::string> &output);
+ static void Split(const std::string& input,
+ std::vector<std::string>& output);
+
+ static std::string::size_type Find(const std::string& input);
- static std::string::size_type Find(const std::string &input);
+ static bool IsValidTargetName(const std::string& input);
- static bool IsValidTargetName(const std::string &input);
+ static std::string StripEmptyListElements(const std::string& input);
- static std::string StripEmptyListElements(const std::string &input);
private:
- cmGeneratorExpression(const cmGeneratorExpression &);
- void operator=(const cmGeneratorExpression &);
+ cmGeneratorExpression(const cmGeneratorExpression&);
+ void operator=(const cmGeneratorExpression&);
cmListFileBacktrace Backtrace;
};
@@ -83,35 +85,34 @@ public:
bool quiet = false,
cmGeneratorTarget const* headTarget = 0,
cmGeneratorTarget const* currentTarget = 0,
- cmGeneratorExpressionDAGChecker *dagChecker = 0,
+ cmGeneratorExpressionDAGChecker* dagChecker = 0,
std::string const& language = std::string()) const;
const char* Evaluate(cmLocalGenerator* lg, const std::string& config,
- bool quiet,
- cmGeneratorTarget const* headTarget,
- cmGeneratorExpressionDAGChecker *dagChecker,
+ bool quiet, cmGeneratorTarget const* headTarget,
+ cmGeneratorExpressionDAGChecker* dagChecker,
std::string const& language = std::string()) const;
/** Get set of targets found during evaluations. */
std::set<cmGeneratorTarget*> const& GetTargets() const
- { return this->DependTargets; }
+ {
+ return this->DependTargets;
+ }
std::set<std::string> const& GetSeenTargetProperties() const
- { return this->SeenTargetProperties; }
+ {
+ return this->SeenTargetProperties;
+ }
std::set<cmGeneratorTarget const*> const& GetAllTargetsSeen() const
- { return this->AllTargetsSeen; }
+ {
+ return this->AllTargetsSeen;
+ }
~cmCompiledGeneratorExpression();
- std::string const& GetInput() const
- {
- return this->Input;
- }
+ std::string const& GetInput() const { return this->Input; }
- cmListFileBacktrace GetBacktrace() const
- {
- return this->Backtrace;
- }
+ cmListFileBacktrace GetBacktrace() const { return this->Backtrace; }
bool GetHadContextSensitiveCondition() const
{
return this->HadContextSensitiveCondition;
@@ -131,19 +132,20 @@ public:
}
void GetMaxLanguageStandard(cmGeneratorTarget const* tgt,
- std::map<std::string, std::string>& mapping);
+ std::map<std::string, std::string>& mapping);
private:
- const char* EvaluateWithContext(cmGeneratorExpressionContext& context,
- cmGeneratorExpressionDAGChecker *dagChecker) const;
+ const char* EvaluateWithContext(
+ cmGeneratorExpressionContext& context,
+ cmGeneratorExpressionDAGChecker* dagChecker) const;
cmCompiledGeneratorExpression(cmListFileBacktrace const& backtrace,
- const std::string& input);
+ const std::string& input);
friend class cmGeneratorExpression;
- cmCompiledGeneratorExpression(const cmCompiledGeneratorExpression &);
- void operator=(const cmCompiledGeneratorExpression &);
+ cmCompiledGeneratorExpression(const cmCompiledGeneratorExpression&);
+ void operator=(const cmCompiledGeneratorExpression&);
cmListFileBacktrace Backtrace;
std::vector<cmGeneratorExpressionEvaluator*> Evaluators;
@@ -154,11 +156,12 @@ private:
mutable std::set<cmGeneratorTarget const*> AllTargetsSeen;
mutable std::set<std::string> SeenTargetProperties;
mutable std::map<cmGeneratorTarget const*,
- std::map<std::string, std::string> > MaxLanguageStandard;
+ std::map<std::string, std::string> >
+ MaxLanguageStandard;
mutable std::string Output;
mutable bool HadContextSensitiveCondition;
mutable bool HadHeadSensitiveCondition;
- mutable std::set<cmGeneratorTarget const*> SourceSensitiveTargets;
+ mutable std::set<cmGeneratorTarget const*> SourceSensitiveTargets;
bool EvaluateForBuildsystem;
};