* @brief Converts all characters in @a str to upper case. * * For example, "Crazy Willy" is converted into "CRAZY WILLY" . */
| 381 | * For example, <tt>"Crazy Willy"</tt> is converted into <tt>"CRAZY WILLY"</tt>. |
| 382 | */ |
| 383 | std::string toUpper(std::string str) { |
| 384 | std::transform(str.begin(), str.end(), str.begin(), |
| 385 | [](const unsigned char c) { return std::toupper(c); }); |
| 386 | return str; |
| 387 | } |
| 388 | |
| 389 | /** |
| 390 | * @brief Converts @a str to wide string. |