Alternative: 
    
    
    let mybuf: ptr uint8 = ...
    let mybufLenInBytes: int = ...
    var s = newSeq[uint8](mybufLenInBytes)
    if mybufLenInBytes != 0:
      copyMem(addr s[0], mybuf, mybufLenInBytes)
    
    
    Run

Reply via email to