---
name: "std::binary_function"
section: "3cxx"
platform: "linux"
package: "libstdc++-12-doc"
version: "12.4.0-5"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/std::binary_function/3cxx"
---

# std::binary\_function(3cxx)

## NAME

std::binary\_function\< \_Arg1, \_Arg2, \_Result \>

## SYNOPSIS

`#include <functional>`

Inherited by std::\_Sp\_owner\_less\< shared\_ptr\< \_Tp \>, weak\_ptr\< \_Tp \> \>, std::\_Sp\_owner\_less\< weak\_ptr\< \_Tp \>, shared\_ptr\< \_Tp \> \>, std::\_Sp\_owner\_less\< \_\_shared\_ptr\< \_Tp, \_Lp \>, \_\_weak\_ptr\< \_Tp, \_Lp \> \>, std::\_Sp\_owner\_less\< \_\_weak\_ptr\< \_Tp, \_Lp \>, \_\_shared\_ptr\< \_Tp, \_Lp \> \>, std::\_Sp\_owner\_less\< void, void \>, **std::equal\_to\< \_Key \>**, **std::equal\_to\< \_Value \>**, **std::less\< typename \_Sequence::value\_type \>**, **\_\_gnu\_parallel::\_Multiplies\< \_Tp1, \_Tp2, \_Result \>**, **\_\_gnu\_parallel::\_Plus\< \_Tp1, \_Tp2, \_Result \>**, and **std::pointer\_to\_binary\_function\< \_Arg1, \_Arg2, \_Result \>**.

### Public Types

**typedef** **\_Arg1** **first\_argument\_type**\
 `first_argument_type` is the type of the first argument  **typedef** \_Result **result\_type**\
 `result_type` is the return type  **typedef** **\_Arg2** **second\_argument\_type**\
 `second_argument_type` is the type of the second argument

## Detailed Description

### template\<typename \_Arg1, typename \_Arg2, typename \_Result\>

struct std::binary\_function\< \_Arg1, \_Arg2, \_Result \>"Helper for defining adaptable binary function objects.

**Deprecated**

Deprecated in C++11, no longer in the standard since C++17.

## Member Typedef Documentation

### template\<typename \_Arg1 , typename \_Arg2 , typename \_Result \> typedef \_Arg1 std::binary\_function\< \_Arg1, \_Arg2, \_Result \>::first\_argument\_type

`first_argument_type` is the type of the first argument

### template\<typename \_Arg1 , typename \_Arg2 , typename \_Result \> typedef \_Result std::binary\_function\< \_Arg1, \_Arg2, \_Result \>::result\_type

`result_type` is the return type

### template\<typename \_Arg1 , typename \_Arg2 , typename \_Result \> typedef \_Arg2 std::binary\_function\< \_Arg1, \_Arg2, \_Result \>::second\_argument\_type

`second_argument_type` is the type of the second argument

## Author

Generated automatically by Doxygen for libstdc++ from the source code.
