/usr/include/boost/units
NameSizeModeActions
base_units/-0755rm
detail/-0755rm
physical_dimensions/-0755rm
systems/-0755rm
absolute.hpp55400644editdlrm
base_dimension.hpp36920644editdlrm
base_unit.hpp41320644editdlrm
cmath.hpp205920644editdlrm
config.hpp28290644editdlrm
conversion.hpp95180644editdlrm
derived_dimension.hpp64650644editdlrm
dim.hpp47450644editdlrm
dimension.hpp44030644editdlrm
dimensionless_quantity.hpp9950644editdlrm
dimensionless_type.hpp13150644editdlrm
dimensionless_unit.hpp9570644editdlrm
get_dimension.hpp12210644editdlrm
get_system.hpp11650644editdlrm
heterogeneous_system.hpp122580644editdlrm
homogeneous_system.hpp23990644editdlrm
io.hpp324700644editdlrm
is_dim.hpp8850644editdlrm
is_dimensionless.hpp11070644editdlrm
is_dimensionless_quantity.hpp9360644editdlrm
is_dimensionless_unit.hpp9050644editdlrm
is_dimension_list.hpp10570644editdlrm
is_quantity.hpp9160644editdlrm
is_quantity_of_dimension.hpp11150644editdlrm
is_quantity_of_system.hpp10970644editdlrm
is_unit.hpp8790644editdlrm
is_unit_of_dimension.hpp11380644editdlrm
is_unit_of_system.hpp11270644editdlrm
lambda.hpp268410644editdlrm
limits.hpp43450644editdlrm
make_scaled_unit.hpp18170644editdlrm
make_system.hpp49140644editdlrm
operators.hpp62870644editdlrm
physical_dimensions.hpp45320644editdlrm
pow.hpp30330644editdlrm
quantity.hpp418600644editdlrm
reduce_unit.hpp8680644editdlrm
scale.hpp50620644editdlrm
scaled_base_unit.hpp36430644editdlrm
static_constant.hpp24250644editdlrm
static_rational.hpp104350644editdlrm
unit.hpp134490644editdlrm
units_fwd.hpp21910644editdlrm
Edit: /usr/include/boost/units/pow.hpp (3033B)
// Boost.Units - A C++ library for zero-overhead dimensional analysis and // unit/quantity manipulation and conversion // // Copyright (C) 2003-2008 Matthias Christian Schabel // Copyright (C) 2008 Steven Watanabe // // Distributed under the Boost Software License, Version 1.0. (See // accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt) #ifndef BOOST_UNITS_POW_HPP #define BOOST_UNITS_POW_HPP #include #include #include #include /// \file /// \brief Raise values to exponents known at compile-time. namespace boost { namespace units { /// raise a value to a @c static_rational power. template BOOST_CONSTEXPR inline typename power_typeof_helper::type pow(const Y& x) { return power_typeof_helper::value(x); } /// raise a value to an integer power. template BOOST_CONSTEXPR inline typename power_typeof_helper >::type pow(const Y& x) { return power_typeof_helper >::value(x); } #ifndef BOOST_UNITS_DOXYGEN /// raise @c T to a @c static_rational power. template struct power_typeof_helper > { typedef typename mpl::if_, double, T>::type internal_type; typedef detail::static_rational_power_impl, internal_type> impl; typedef typename impl::type type; static BOOST_CONSTEXPR type value(const T& x) { return impl::call(x); } }; /// raise @c float to a @c static_rational power. template struct power_typeof_helper > { // N.B. pathscale doesn't accept inheritance for some reason. typedef power_typeof_helper > base; typedef typename base::type type; static BOOST_CONSTEXPR type value(const double& x) { return base::value(x); } }; #endif /// take the @c static_rational root of a value. template BOOST_CONSTEXPR typename root_typeof_helper::type root(const Y& x) { return root_typeof_helper::value(x); } /// take the integer root of a value. template BOOST_CONSTEXPR typename root_typeof_helper >::type root(const Y& x) { return root_typeof_helper >::value(x); } #ifndef BOOST_UNITS_DOXYGEN /// take @c static_rational root of an @c T template struct root_typeof_helper > { // N.B. pathscale doesn't accept inheritance for some reason. typedef power_typeof_helper > base; typedef typename base::type type; static BOOST_CONSTEXPR type value(const T& x) { return(base::value(x)); } }; #endif } // namespace units } // namespace boost #endif // BOOST_UNITS_STATIC_RATIONAL_HPP