Skip to content

Commit

Permalink
utils.h: added bool_to_string()
Browse files Browse the repository at this point in the history
  • Loading branch information
firewave committed Aug 23, 2023
1 parent 0f8d96a commit fb4bbd7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -325,4 +325,9 @@ static inline std::string ptr_to_string(const void* p)
#endif
}

static inline std::string bool_to_string(bool b)
{
return b ? "true" : "false";
}

#endif

0 comments on commit fb4bbd7

Please sign in to comment.