Commit 6d8eb3f7 authored by Lynn Garren's avatar Lynn Garren
Browse files

Merge branch 'release/CLHEP_2_2_0_7'

parents 3c4a5291 6f18b95e
......@@ -9,6 +9,17 @@
//
// ======================================================================
// don't generate unnecessary warnings
#if defined __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdelete-non-virtual-dtor"
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdelete-non-virtual-dtor"
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#endif
#include "CLHEP/Utility/defs.h"
......@@ -1355,6 +1366,13 @@ template< typename P, typename R >
} // namespace CLHEP
#if defined __GNUC__
#pragma GCC diagnostic pop
#endif
#ifdef __clang__
#pragma clang diagnostic pop
#endif
#endif // CLHEP_TYPE_TRAITS_H
......
......@@ -9,7 +9,7 @@
# ----------------------------------------------------------------------
AC_PREREQ(2.59)
AC_INIT(CLHEP Utility, 2.2.0.6, http://savannah.cern.ch/projects/clhep/, Utility)
AC_INIT(CLHEP Utility, 2.2.0.7, http://savannah.cern.ch/projects/clhep/, Utility)
AC_CONFIG_AUX_DIR(autotools)
AC_CANONICAL_TARGET
AM_INIT_AUTOMAKE(1.9 foreign)
......
remove_definitions(-DNDEBUG)
clhep_enable_asserts()
set( Utility_simple_tests testNoncopyable
testPrimaryTraits
......
......@@ -387,12 +387,12 @@ int
assert(evaluate<char const >() == cat_int);
assert(evaluate<char volatile >() == cat_int);
assert(evaluate<char const volatile >() == cat_int);
typedef signed char schar __attribute__((unused));
typedef signed char schar ;
assert(evaluate<schar >() == cat_int);
assert(evaluate<schar const >() == cat_int);
assert(evaluate<schar volatile >() == cat_int);
assert(evaluate<schar const volatile >() == cat_int);
typedef unsigned char uchar __attribute__((unused));
typedef unsigned char uchar ;
assert(evaluate<uchar >() == cat_int);
assert(evaluate<uchar const >() == cat_int);
assert(evaluate<uchar volatile >() == cat_int);
......@@ -401,7 +401,7 @@ int
assert(evaluate<short const >() == cat_int);
assert(evaluate<short volatile >() == cat_int);
assert(evaluate<short const volatile >() == cat_int);
typedef unsigned short ushort_local __attribute__((unused));
typedef unsigned short ushort_local ;
assert(evaluate<ushort_local >() == cat_int);
assert(evaluate<ushort_local const >() == cat_int);
assert(evaluate<ushort_local volatile >() == cat_int);
......@@ -410,7 +410,7 @@ int
assert(evaluate<int const >() == cat_int);
assert(evaluate<int volatile >() == cat_int);
assert(evaluate<int const volatile >() == cat_int);
typedef unsigned int uint_local __attribute__((unused));
typedef unsigned int uint_local ;
assert(evaluate<uint_local >() == cat_int);
assert(evaluate<uint_local const >() == cat_int);
assert(evaluate<uint_local volatile >() == cat_int);
......@@ -419,7 +419,7 @@ int
assert(evaluate<long const >() == cat_int);
assert(evaluate<long volatile >() == cat_int);
assert(evaluate<long const volatile >() == cat_int);
typedef unsigned long ulong_local __attribute__((unused));
typedef unsigned long ulong_local ;
assert(evaluate<ulong_local >() == cat_int);
assert(evaluate<ulong_local const >() == cat_int);
assert(evaluate<ulong_local volatile >() == cat_int);
......@@ -434,7 +434,7 @@ int
assert(evaluate<double const >() == cat_flt);
assert(evaluate<double volatile >() == cat_flt);
assert(evaluate<double const volatile >() == cat_flt);
typedef long double ldouble __attribute__((unused));
typedef long double ldouble ;
assert(evaluate<ldouble >() == cat_flt);
assert(evaluate<ldouble const >() == cat_flt);
assert(evaluate<ldouble volatile >() == cat_flt);
......
......@@ -18,6 +18,15 @@
#include <cassert>
#if defined __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#endif
using namespace CLHEP;
......@@ -544,3 +553,4 @@ int main()
return 0;
}
......@@ -19,6 +19,14 @@
#include <map>
#include <vector>
#if defined __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#endif
using namespace CLHEP;
using CLHEP::shared_ptr;
......@@ -377,7 +385,7 @@ void
}
void
deleter2(int * p __attribute__((unused)))
deleter2(int * p )
{
assert(p == &m);
++*p;
......@@ -386,7 +394,7 @@ void
// don't generate warnings about unused parameter inside assert
struct deleter3
{
void operator()(incomplete * p __attribute__((unused)))
void operator()(incomplete * p )
{
assert(p == 0);
}
......@@ -962,7 +970,7 @@ void
// don't generate warnings about unused variable q
{
std::auto_ptr<int> p(new int(7));
int * q __attribute__((unused))= p.get();
int * q = p.get();
shared_ptr<int> pi(p);
assert(pi? true: false);
assert(!!pi);
......@@ -976,7 +984,7 @@ void
{
std::auto_ptr<int> p(new int(7));
int * q __attribute__((unused))= p.get();
int * q = p.get();
shared_ptr<int const> pi(p);
assert(pi? true: false);
assert(!!pi);
......@@ -990,7 +998,7 @@ void
{
std::auto_ptr<int> p(new int(7));
int * q __attribute__((unused))= p.get();
int * q = p.get();
shared_ptr<void> pv(p);
assert(pv? true: false);
assert(!!pv);
......@@ -1003,7 +1011,7 @@ void
{
std::auto_ptr<int> p(new int(7));
int * q __attribute__((unused))= p.get();
int * q = p.get();
shared_ptr<void const> pv(p);
assert(pv? true: false);
assert(!!pv);
......@@ -1018,7 +1026,7 @@ void
{
std::auto_ptr<X> p(new X);
X * q __attribute__((unused)) = p.get();
X * q = p.get();
shared_ptr<X> px(p);
assert(px? true: false);
assert(!!px);
......@@ -1034,7 +1042,7 @@ void
{
std::auto_ptr<X> p(new X);
X * q __attribute__((unused)) = p.get();
X * q = p.get();
shared_ptr<X const> px(p);
assert(px? true: false);
assert(!!px);
......@@ -1050,7 +1058,7 @@ void
{
std::auto_ptr<X> p(new X);
X * q __attribute__((unused)) = p.get();
X * q = p.get();
shared_ptr<void> pv(p);
assert(pv? true: false);
assert(!!pv);
......@@ -1066,7 +1074,7 @@ void
{
std::auto_ptr<X> p(new X);
X * q __attribute__((unused)) = p.get();
X * q = p.get();
shared_ptr<void const> pv(p);
assert(pv? true: false);
assert(!!pv);
......@@ -1083,7 +1091,7 @@ void
{
std::auto_ptr<Y> p(new Y);
Y * q __attribute__((unused)) = p.get();
Y * q = p.get();
shared_ptr<X> px(p);
assert(px? true: false);
assert(!!px);
......@@ -1101,7 +1109,7 @@ void
{
std::auto_ptr<Y> p(new Y);
Y * q __attribute__((unused)) = p.get();
Y * q = p.get();
shared_ptr<X const> px(p);
assert(px? true: false);
assert(!!px);
......@@ -3383,3 +3391,10 @@ shared_ptr<X> createX()
}
} // namespace n_spt_abstract
#if defined __GNUC__
#pragma GCC diagnostic pop
#endif
#ifdef __clang__
#pragma clang diagnostic pop
#endif
......@@ -18,6 +18,14 @@
#include <cassert>
#if defined __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#endif
using namespace CLHEP;
using CLHEP::shared_ptr;
......@@ -245,8 +253,8 @@ int main()
weak_ptr<X> wp5;
bool b1 __attribute__((unused)) = wp1 < wp5;
bool b2 __attribute__((unused)) = wp5 < wp1;
bool b1 = wp1 < wp5;
bool b2 = wp5 < wp1;
p5.reset();
......@@ -272,3 +280,10 @@ int main()
return 0;
} // main()
#if defined __GNUC__
#pragma GCC diagnostic pop
#endif
#ifdef __clang__
#pragma clang diagnostic pop
#endif
......@@ -18,6 +18,14 @@
#include <cassert>
#if defined __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#endif
using namespace CLHEP;
using CLHEP::shared_ptr;
......@@ -64,3 +72,10 @@ int main()
return 0;
}
#if defined __GNUC__
#pragma GCC diagnostic pop
#endif
#ifdef __clang__
#pragma clang diagnostic pop
#endif
......@@ -19,6 +19,15 @@
#include <map>
#include <vector>
#if defined __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#endif
using namespace CLHEP;
using CLHEP::shared_ptr;
......@@ -1018,8 +1027,8 @@ void
assert(wp < wp2 || wp2 < wp);
assert(!(wp < wp2 && wp2 < wp));
bool b1 __attribute__((unused)) = wp < wp2;
bool b2 __attribute__((unused)) = wp2 < wp;
bool b1 = wp < wp2;
bool b2 = wp2 < wp;
{
weak_ptr<X> wp3(wp);
......@@ -1067,8 +1076,8 @@ void
assert(wp < wp2 || wp2 < wp);
assert(!(wp < wp2 && wp2 < wp));
bool b1 __attribute__((unused)) = wp < wp2;
bool b2 __attribute__((unused)) = wp2 < wp;
bool b1 = wp < wp2;
bool b2 = wp2 < wp;
{
weak_ptr<X> wp3(wp);
......@@ -1136,8 +1145,8 @@ void
assert(!(wp < wp2 || wp2 < wp));
assert(!(wp < wp2 && wp2 < wp));
bool b1 __attribute__((unused)) = wp < wp2;
bool b2 __attribute__((unused)) = wp2 < wp;
bool b1 = wp < wp2;
bool b2 = wp2 < wp;
{
weak_ptr<X> wp3(wp);
......@@ -1383,3 +1392,10 @@ shared_ptr<incomplete>
shared_ptr<incomplete> px(new incomplete);
return px;
}
#if defined __GNUC__
#pragma GCC diagnostic pop
#endif
#ifdef __clang__
#pragma clang diagnostic pop
#endif
......@@ -9,7 +9,7 @@
# ----------------------------------------------------------------------
AC_PREREQ(2.59)
AC_INIT(CLHEP Vector, 2.2.0.6, http://savannah.cern.ch/projects/clhep/, Vector)
AC_INIT(CLHEP Vector, 2.2.0.7, http://savannah.cern.ch/projects/clhep/, Vector)
AC_CONFIG_AUX_DIR(autotools)
AC_CANONICAL_TARGET
AC_CONFIG_SRCDIR([src/AxisAngle.cc])
......
remove_definitions(-DNDEBUG)
clhep_enable_asserts()
set( Vector_tests testThreeVector
testLorentzVector )
......
......@@ -10,7 +10,7 @@
#include "CLHEP/Units/GlobalPhysicalConstants.h"
#include "CLHEP/Vector/Rotation.h"
#include "CLHEP/Vector/ThreeVector.h"
#include <assert.h>
#include <cassert>
#include <cmath>
#include <stdlib.h>
......@@ -25,9 +25,9 @@ typedef Hep3Vector Vector;
int main() {
int i,k;
double angA=CLHEP::pi/3, angB=CLHEP::pi/4, angC=CLHEP::pi/6;
double cosA __attribute__((unused))=std::cos(angA), sinA __attribute__((unused))=std::sin(angA);
double cosB __attribute__((unused))=std::cos(angB), sinB __attribute__((unused))=std::sin(angB);
double cosC __attribute__((unused))=std::cos(angC), sinC __attribute__((unused))=std::sin(angC);
double cosA =std::cos(angA), sinA =std::sin(angA);
double cosB =std::cos(angB), sinB =std::sin(angB);
double cosC =std::cos(angC), sinC =std::sin(angC);
Rotation R; // default constructor
assert ( R.xx() == 1 );
......
......@@ -18,6 +18,7 @@
#
# clhep_lib_suffix();
# check for -DLIB_SUFFIX=xxx and process intelligently
#
macro( clhep_autoconf_variables )
......@@ -180,9 +181,9 @@ macro( _clhep_check_cxxstd )
##message(STATUS "_clhep_check_cxxstd debug: CLHEP_BUILD_CXXSTD HAVE_STDCXX: ${CLHEP_BUILD_CXXSTD} ${HAVE_STDCXX}")
if( DEFINED HAVE_STDCXX )
if( ${CMAKE_CXX_COMPILER_ID} STREQUAL "Clang" )
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CLHEP_BUILD_CXXSTD} -pthread -Wno-deprecated-declarations" )
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CLHEP_BUILD_CXXSTD} -pthread" )
elseif(CMAKE_COMPILER_IS_GNUCXX)
set( CMAKE_CXX_FLAGS "${CLHEP_BUILD_CXXSTD} -pthread -Wno-deprecated-declarations ${CMAKE_CXX_FLAGS}" )
set( CMAKE_CXX_FLAGS "${CLHEP_BUILD_CXXSTD} -pthread ${CMAKE_CXX_FLAGS}" )
else()
message(STATUS "clhep_set_compiler_flags: Do not know how to set c++11 extensions for ${CMAKE_CXX_COMPILER_ID}")
endif()
......@@ -190,7 +191,7 @@ macro( _clhep_check_cxxstd )
endmacro( _clhep_check_cxxstd )
macro( _clhep_check_for_pthread )
message(STATUS "_clhep_check_for_pthread debug: CMAKE_CXX_FLAGS: ${CMAKE_CXX_FLAGS}")
##message(STATUS "_clhep_check_for_pthread debug: CMAKE_CXX_FLAGS: ${CMAKE_CXX_FLAGS}")
set( HAVE_STDCXX )
if( NOT "${CMAKE_CXX_FLAGS}" STREQUAL "" )
string(REGEX REPLACE " " ";" flag_list ${CMAKE_CXX_FLAGS})
......@@ -398,3 +399,9 @@ macro( clhep_lib_suffix )
endif()
message(STATUS "libraries will be installed in $ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}")
endmacro( clhep_lib_suffix )
macro( clhep_enable_asserts )
string(REGEX REPLACE "-DNDEBUG" " " CXXFLAGS "${CXXFLAGS}" )
string(TOUPPER ${CMAKE_BUILD_TYPE} BTYPE_UC )
string(REGEX REPLACE "-DNDEBUG" " " CMAKE_CXX_FLAGS_${BTYPE_UC} "${CMAKE_CXX_FLAGS_${BTYPE_UC}}" )
endmacro( clhep_enable_asserts )
......@@ -9,7 +9,7 @@
# ----------------------------------------------------------------------
AC_PREREQ(2.59)
AC_INIT(CLHEP, 2.2.0.6, http://savannah.cern.ch/projects/clhep/ )
AC_INIT(CLHEP, 2.2.0.7, http://savannah.cern.ch/projects/clhep/ )
AC_CANONICAL_TARGET
AC_CONFIG_SRCDIR([Vector/src/AxisAngle.cc])
AM_INIT_AUTOMAKE(1.9 foreign)
......
......@@ -4,7 +4,7 @@
# Project related configuration options
#---------------------------------------------------------------------------
PROJECT_NAME = CLHEP
PROJECT_NUMBER = 2.2.0.6
PROJECT_NUMBER = 2.2.0.7
OUTPUT_DIRECTORY =
CREATE_SUBDIRS = NO
OUTPUT_LANGUAGE = English
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment