Back to Arangodb

BOOST_PP_GREATER

3rdParty/boost/1.78.0/libs/preprocessor/doc/ref/greater.html

3.12.9.11.4 KB
Original Source

The BOOST_PP_GREATER macro compares two values for greater magnitude.

Usage

BOOST_PP_GREATER (x, y)

Arguments

x The left operand of the comparison. Valid values range from 0 to BOOST_PP_LIMIT_MAG. y The right operand of the comparison. Valid values range from 0 to BOOST_PP_LIMIT_MAG.

Remarks

If x is greater than y, this macro expands to 1. Otherwise, it expands to 0.

Previously, this macro could not be used inside BOOST_PP_WHILE. There is no longer any such restriction. It is more efficient, however, to use BOOST_PP_GREATER_D in such a situation.

See Also

Requirements

Header: <boost/preprocessor/comparison/greater.hpp>

Sample Code

#include <[boost/preprocessor/comparison/greater.hpp](../headers/comparison/greater.html)>[BOOST\_PP\_GREATER](greater.html)(4, 3) // expands to 1[BOOST\_PP\_GREATER](greater.html)(5, 5) // expands to 0

Copyright Housemarque Oy 2002 Copyright Paul Mensonides 2002

Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at www.boost.org/LICENSE_1_0.txt)