IntToU64WithError
Description
Convert an integer to u64.
Parameters
| Name | Direction | Description |
|---|---|---|
value |
in | Integer to convert |
error |
out | Optional pointer set to true on failure and false on success |
Returns
The numeric value as u64, or 0 on failure.
Usage example (Cross-references)
Usage examples (Cross-references)
- In
Int.c:392:
}
u64 IntToU64WithError(Int *value, bool *error) {
u64 out = 0;
bool ok = IntTryToU64(value, &out);- In
Convert.h:186:
static inline u64 MISRA_PRIV_IntToU64NoError(Int *value) {
return IntToU64WithError(value, NULL);
}- In
Convert.h:190:
#define MISRA_PRIV_INT_TO_U64_SELECT(_1, _2, NAME, ...) NAME
#define IntToU64(...) MISRA_PRIV_INT_TO_U64_SELECT(__VA_ARGS__, IntToU64WithError, MISRA_PRIV_IntToU64NoError)(__VA_ARGS__)
#endif // MISRA_STD_CONTAINER_INT_CONVERT_H
Last updated on