src/stdlib/bytes.panack
Green: covered; red: known zero; amber: unavailable. Blank lines are outside the executable-start-line denominator.
1 pure bytes_empty(): Bytes { 2 bytes() 3 } 4 5 pure bytes_push(buffer: Bytes, value: Nat): Bytes { 6 byte_append(buffer, value) 7 } 8 9 pure bytes_join(left: Bytes, right: Bytes): Bytes { 10 bytes_concat(left, right) 11 } 12 13 pure bytes_length(buffer: Bytes): Nat { 14 byte_len(buffer) 15 } 16 17 pure bytes_at(buffer: Bytes, index: Nat): Nat { 18 byte_get(buffer, index) 19 } 20 21 pure text_encode_utf8(value: Str): Bytes { 22 utf8_encode(value) 23 } 24 25 pure text_decode_utf8(buffer: Bytes): Str { 26 utf8_decode(buffer) 27 } 28
Functions
[
{
"id": "declaration/0",
"name": "bytes_empty",
"line": 1,
"state": "zero",
"entries": "0"
},
{
"id": "declaration/1",
"name": "bytes_push",
"line": 5,
"state": "covered",
"entries": "1"
},
{
"id": "declaration/2",
"name": "bytes_join",
"line": 9,
"state": "zero",
"entries": "0"
},
{
"id": "declaration/3",
"name": "bytes_length",
"line": 13,
"state": "covered",
"entries": "1"
},
{
"id": "declaration/4",
"name": "bytes_at",
"line": 17,
"state": "zero",
"entries": "0"
},
{
"id": "declaration/5",
"name": "text_encode_utf8",
"line": 21,
"state": "covered",
"entries": "1"
},
{
"id": "declaration/6",
"name": "text_decode_utf8",
"line": 25,
"state": "covered",
"entries": "1"
}
]Source branch outcomes
[]
Reviewed declaration exclusions
[]