Fixes for deprecated std::basic_string::reserve()

This commit is contained in:
William S Fulton 2022-07-30 23:21:21 +01:00
commit ffbde7a132
3 changed files with 32 additions and 1 deletions

View file

@ -15,6 +15,11 @@ if li_std_string_extra.test_value(x) != x:
if li_std_string_extra.test_const_reference(x) != x:
raise RuntimeError("bad string mapping")
s = li_std_string_extra.string("1234567890")
size = s.size()
if size != 10:
raise "Incorrect size"
s.shrink_to_fit()
s = li_std_string_extra.string("he")
#s += "ll"