Stan
2.5.0
probability, sampling & optimization
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
src
stan
math
functions
as_bool.hpp
Go to the documentation of this file.
1
#ifndef STAN__MATH__FUNCTIONS__AS_BOOL_HPP
2
#define STAN__MATH__FUNCTIONS__AS_BOOL_HPP
3
4
namespace
stan {
5
namespace
math {
6
13
template
<
typename
T>
14
inline
bool
as_bool
(
const
T x) {
15
return
x != 0;
16
}
17
18
}
19
}
20
21
#endif
stan::math::as_bool
bool as_bool(const T x)
Return 1 if the argument is unequal to zero and 0 otherwise.
Definition:
as_bool.hpp:14
[
Stan Home Page
]
© 2011–2014, Stan Development Team.