You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
How to use each, how to use with temporary allocator
coppamocha — Today at 09:36
do we need to free Strings or are they automatically freed.
asking this cuz, i tried .free() method and the program aborts:
free(): invalid pointer
[09:37]
is this because maybe the string is allocated on stack?
[09:38]
if so, is there a way to detect if the string was allocated on stack?
Christoffer L — Today at 10:36
No, you need to know where this String comes from @coppamocha. That is one of the drawbacks of using String. You can use the DString if you want to have something that knows how to free itself.
string.iterator() iterates over codepoints, so you get Char32 back
The text was updated successfully, but these errors were encountered:
joshring
changed the title
Write a page on strings, DString ZString
Write a page on strings, DString ZString CString
Oct 7, 2024
joshring
changed the title
Write a page on strings, DString ZString CString
Write a page on String, DString ZString CString
Oct 7, 2024
joshring
changed the title
Write a page on String, DString ZString CString
Write a page on String, DString, ZString, CString
Oct 7, 2024
joshring
changed the title
Write a page on String, DString, ZString, CString
Write a page on String, DString, ZString
Oct 10, 2024
How to use each, how to use with temporary allocator
The text was updated successfully, but these errors were encountered: