LCOV - code coverage report
Current view: top level - src - byte.c (source / functions) Hit Total Coverage
Test: Code coverage Lines: 8 8 100.0 %
Date: 2026-07-14 21:28:07 Functions: 2 2 100.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 2 2 100.0 %

           Branch data     Line data    Source code
       1                 :            : // Copyright 2019-2026 David Robillard <d@drobilla.net>
       2                 :            : // SPDX-License-Identifier: ISC
       3                 :            : 
       4                 :            : #include "fixed.h"
       5                 :            : 
       6                 :            : #include <exess/exess.h>
       7                 :            : 
       8                 :            : #include <stdint.h>
       9                 :            : #include <stdlib.h>
      10                 :            : 
      11                 :            : EXESS_NONBLOCKING ExessResult
      12                 :        276 : exess_read_byte(const char* const str, int8_t* const out)
      13                 :            : {
      14                 :        276 :   int64_t           value = 0;
      15                 :        276 :   const ExessResult r     = read_signed(str, INT8_MIN, INT8_MAX, &value);
      16                 :            : 
      17         [ +  + ]:        276 :   if (!r.status) {
      18                 :        272 :     *out = (int8_t)value;
      19                 :            :   }
      20                 :            : 
      21                 :        276 :   return r;
      22                 :            : }
      23                 :            : 
      24                 :            : EXESS_NONBLOCKING EXESS_NONBLOCKING ExessResult
      25                 :        322 : exess_write_byte(const int8_t value, const size_t buf_size, char* const buf)
      26                 :            : {
      27                 :        322 :   return exess_write_long(value, buf_size, buf);
      28                 :            : }

Generated by: LCOV version 1.16