From 99085af972d03ffbb3ef290a7a604cc732b2489e Mon Sep 17 00:00:00 2001 From: David van der Spoel Date: Thu, 9 May 2013 18:29:35 +0200 Subject: [PATCH] Fixed two compilation issues. With new compilers and boost 1.5.3, since that version adds an "explicit operator bool()" to the smart pointer classes, if the compiler supports it. Change-Id: I31862314479990adc8333e834dd16cbddbfcc387 --- src/gromacs/selection/parsetree.h | 2 +- src/gromacs/utility/exceptions.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gromacs/selection/parsetree.h b/src/gromacs/selection/parsetree.h index a313c2ecde..6961a7503c 100644 --- a/src/gromacs/selection/parsetree.h +++ b/src/gromacs/selection/parsetree.h @@ -213,7 +213,7 @@ class SelectionParserValue } //! Returns true if the value comes from expression evaluation. - bool hasExpressionValue() const { return expr; } + bool hasExpressionValue() const { return static_cast(expr); } //! Returns the string value (\a type must be ::STR_VALUE). const std::string &stringValue() const diff --git a/src/gromacs/utility/exceptions.cpp b/src/gromacs/utility/exceptions.cpp index 8c229a6054..1854b5e820 100644 --- a/src/gromacs/utility/exceptions.cpp +++ b/src/gromacs/utility/exceptions.cpp @@ -78,7 +78,7 @@ class ErrorMessage explicit ErrorMessage(const std::string &text); //! Whether this object is a context string. - bool isContext() const { return child_; } + bool isContext() const { return static_cast(child_); } //! Returns the text for this object. const std::string &text() const { return text_; } /*! \brief -- 2.22.0