开发者

Check if std::wstring is null or empty

开发者 https://www.devze.com 2023-02-17 21:17 出处:网络
How to check if an std::wstri开发者_JS百科ng is null or empty?wstring is not a pointer, it cannot be null. You can check if it\'s empty (that is, is equivalent to \"\") either by direct comparison to

How to check if an std::wstri开发者_JS百科ng is null or empty?


wstring is not a pointer, it cannot be null. You can check if it's empty (that is, is equivalent to "") either by direct comparison to the previous, or by:

str.empty(); // == (str.size() == 0)
0

精彩评论

暂无评论...
验证码 换一张
取 消