accidentally not in module

main
Jacob Windle 2023-04-24 11:04:08 -04:00
parent 8665fd5bb4
commit 32b806200d
1 changed files with 4 additions and 3 deletions

View File

@ -35,8 +35,6 @@ function bit_at(byte::UInt8, idx::Int64; t::Type=Int64)::Int64
parse(t, bitstring(byte)[idx])
end
end
# byte_vec_to_string(UInt8.(collect("ABC")))
function bit_vector(byte::UInt8; little_endian=false)::Vector{UInt8}
range = if little_endian
@ -53,4 +51,7 @@ end
function bit_vector(byte_vector::Vector{UInt8}; little_endian=false)::Vector{UInt8}
vecs = [bit_vector(byte; little_endian=little_endian) for byte byte_vector]
reduce(vcat, vecs)
end
end
end
# byte_vec_to_string(UInt8.(collect("ABC")))