tests/heapalloc_str: Test for alloc-free string operations.

Starts with concatenation with an empty string.
This commit is contained in:
Paul Sokolovsky 2017-01-27 00:45:30 +03:00
parent e2e663291d
commit 9ffc3ae0e7
2 changed files with 14 additions and 0 deletions

View File

@ -0,0 +1,14 @@
# String operations which don't require allocation
import micropython
micropython.heap_lock()
b"" + b""
b"" + b"1"
b"2" + b""
"" + ""
"" + "1"
"2" + ""
micropython.heap_unlock()

View File