[Cmake-commits] CMake branch, next, updated. v2.8.9-521-g00d7a29

Stephen Kelly steveire at gmail.com
Thu Sep 13 14:38:03 EDT 2012


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  00d7a294b1ede57c31ee5f71ccdae7fd7d4d6cb7 (commit)
       via  abc580229e28e30b0fc830bb8bc35456a31405b9 (commit)
      from  acb7f7e6b07fb5243daf50fef837cb171f906e80 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=00d7a294b1ede57c31ee5f71ccdae7fd7d4d6cb7
commit 00d7a294b1ede57c31ee5f71ccdae7fd7d4d6cb7
Merge: acb7f7e abc5802
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Thu Sep 13 14:38:02 2012 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Thu Sep 13 14:38:02 2012 -0400

    Merge topic 'generator-expression-refactor' into next
    
    abc5802 Fix some compiler warnings from the dashboard.


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=abc580229e28e30b0fc830bb8bc35456a31405b9
commit abc580229e28e30b0fc830bb8bc35456a31405b9
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Thu Sep 13 20:24:39 2012 +0200
Commit:     Stephen Kelly <steveire at gmail.com>
CommitDate: Thu Sep 13 20:24:39 2012 +0200

    Fix some compiler warnings from the dashboard.
    
    Unused parameters, ordering of initialization in constructors,
    struct/class forward declaration mismatch, and some cleanup of private
    areas of class definitions.

diff --git a/Source/cmGeneratorExpression.h b/Source/cmGeneratorExpression.h
index 713b9ce..b8467c2 100644
--- a/Source/cmGeneratorExpression.h
+++ b/Source/cmGeneratorExpression.h
@@ -19,7 +19,7 @@ class cmTarget;
 class cmMakefile;
 class cmListFileBacktrace;
 
-class cmGeneratorExpressionEvaluator;
+struct cmGeneratorExpressionEvaluator;
 
 class cmCompiledGeneratorExpression;
 
@@ -43,11 +43,10 @@ public:
   const cmCompiledGeneratorExpression& Parse(const char* input);
 
 private:
-  cmListFileBacktrace const& Backtrace;
-private:
   cmGeneratorExpression(const cmGeneratorExpression &);
   void operator=(const cmGeneratorExpression &);
 
+  cmListFileBacktrace const& Backtrace;
   cmCompiledGeneratorExpression *CompiledExpression;
 };
 
@@ -65,21 +64,19 @@ public:
 
 private:
   cmCompiledGeneratorExpression(cmListFileBacktrace const& backtrace,
-                      std::vector<cmGeneratorExpressionEvaluator*> evaluators,
-                      const char *input, bool needsParsing);
+              const std::vector<cmGeneratorExpressionEvaluator*> &evaluators,
+              const char *input, bool needsParsing);
 
   friend class cmGeneratorExpression;
 
-private:
-  const std::vector<cmGeneratorExpressionEvaluator*> Evaluators;
-  cmListFileBacktrace const& Backtrace;
+  cmCompiledGeneratorExpression(const cmCompiledGeneratorExpression &);
+  void operator=(const cmCompiledGeneratorExpression &);
 
-  mutable std::set<cmTarget*> Targets;
+  cmListFileBacktrace const& Backtrace;
+  const std::vector<cmGeneratorExpressionEvaluator*> Evaluators;
   const char* const Input;
   const bool NeedsParsing;
 
+  mutable std::set<cmTarget*> Targets;
   mutable std::string Output;
-private:
-  cmCompiledGeneratorExpression(const cmCompiledGeneratorExpression &);
-  void operator=(const cmCompiledGeneratorExpression &);
 };
diff --git a/Source/cmGeneratorExpressionEvaluator.cxx b/Source/cmGeneratorExpressionEvaluator.cxx
index 194749c..cf24948 100644
--- a/Source/cmGeneratorExpressionEvaluator.cxx
+++ b/Source/cmGeneratorExpressionEvaluator.cxx
@@ -56,9 +56,9 @@ static const struct ZeroNode : public cmGeneratorExpressionNode
 {
   virtual bool GeneratesContent() const { return false; }
 
-  std::string Evaluate(const std::vector<std::string> &parameters,
-                       cmGeneratorExpressionContext *context,
-                       const GeneratorExpressionContent *content) const
+  std::string Evaluate(const std::vector<std::string> &,
+                       cmGeneratorExpressionContext *,
+                       const GeneratorExpressionContent *) const
   {
     // Unreachable
     return std::string();
@@ -70,9 +70,9 @@ static const struct OneNode : public cmGeneratorExpressionNode
 {
   virtual bool AcceptsSingleArbitraryContentParameter() const { return true; }
 
-  std::string Evaluate(const std::vector<std::string> &parameters,
-                       cmGeneratorExpressionContext *context,
-                       const GeneratorExpressionContent *content) const
+  std::string Evaluate(const std::vector<std::string> &,
+                       cmGeneratorExpressionContext *,
+                       const GeneratorExpressionContent *) const
   {
     // Unreachable
     return std::string();
@@ -136,7 +136,7 @@ static const struct ConfigurationNode : public cmGeneratorExpressionNode
 {
   virtual int NumExpectedParameters() const { return 0; }
 
-  std::string Evaluate(const std::vector<std::string> &parameters,
+  std::string Evaluate(const std::vector<std::string> &,
                        cmGeneratorExpressionContext *context,
                        const GeneratorExpressionContent *) const
   {
@@ -428,7 +428,7 @@ std::string GeneratorExpressionContent::Evaluate(
   }
 
   int numExpected = node->NumExpectedParameters();
-  if ((numExpected != -1 && numExpected != parameters.size()))
+  if ((numExpected != -1 && unsigned int(numExpected) != parameters.size()))
     {
     if (numExpected == 0)
       {
diff --git a/Source/cmGeneratorExpressionParser.h b/Source/cmGeneratorExpressionParser.h
index 8bdb1a4..28f1441 100644
--- a/Source/cmGeneratorExpressionParser.h
+++ b/Source/cmGeneratorExpressionParser.h
@@ -21,7 +21,7 @@
 
 class cmMakefile;
 class cmTarget;
-class cmGeneratorExpressionEvaluator;
+struct cmGeneratorExpressionEvaluator;
 
 //----------------------------------------------------------------------------
 struct cmGeneratorExpressionParser

-----------------------------------------------------------------------

Summary of changes:
 Source/cmGeneratorExpression.h            |   21 +++++++++------------
 Source/cmGeneratorExpressionEvaluator.cxx |   16 ++++++++--------
 Source/cmGeneratorExpressionParser.h      |    2 +-
 3 files changed, 18 insertions(+), 21 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list