How to convert a uint32_t value to string!
I have added this:
1 2 3 4 5 6 7
|
uint32_t p5 = 97;
uint32_t p15 = 1613;
uint32_t rath1 = random_range(p5, p15);
std::stringstream ss;
std::string ret;
ss << rath1;
ss >> ret;
|
I dont know if random_range returns an uint32_t value :/
But gets this error
1 2 3
|
../.....cpp:649: error: invalid conversion from `uint32_t' to `const char*'
../.....cpp:649: error: initializing argument 1 of `std::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _CharT*, const _Alloc&) [with _CharT = char, _Traits = std::char_traits<char>, _Alloc = std::allocator<char>]'
|
bump
Topic archived. No new replies allowed.