다음을 통해 공유


is_bind_expression 클래스

Tests if type generated by calling bind.

template<class Ty>
    struct is_bind_expression {
    static const bool value;
    };

설명

The constant value value is true if the type Ty is a type returned by a call to bind, otherwise false.

예제

 

// std_tr1__functional__is_bind_expression.cpp 
// compile with: /EHsc 
#include <functional> 
#include <iostream> 
 
void square(double x) 
    { 
    std::cout << x << "^2 == " << x * x << std::endl; 
    } 
 
template<class Expr> 
    void test_for_bind(const Expr&) 
    { 
    std::cout << std::is_bind_expression<Expr>::value << std::endl; 
    } 
 
int main() 
    { 
    test_for_bind(3.0 * 3.0); 
    test_for_bind(std::bind(square, 3)); 
 
    return (0); 
    } 
 
  

요구 사항

헤더: <기능>

네임스페이스: std

참고 항목

참조

bind 함수