Module ocl::util [] [src]

Utility and debugging functions.

Largely untested.

Stability

Printing functions may be moved/renamed/removed at any time.

Statics

BGC_DEFAULT
BGC_DGR
BGC_GRN
BGC_LGR
BGC_PUR
C_BGRN
C_BLU
C_BRED
C_CYA
C_DBL
C_DEFAULT
C_DGR
C_GRN
C_LBL
C_LGR
C_LRD
C_MAG
C_ORA
C_PUR
C_RED
C_UNDER
C_YEL
TAB

Functions

bytes_into

Converts a vector of bytes into a value of arbitrary type.

bytes_into_vec

Converts a vector of bytes into a vector of arbitrary type.

bytes_to

Copies a slice of bytes to a new value of arbitrary type.

bytes_to_u32

Copies a byte slice to a new u32.

bytes_to_vec

Copies a slice of bytes into a vector of arbitrary type.

into_bytes

[UNTESTED] Copies an arbitrary primitive or struct into core bytes.

padded_len

Pads len to make it evenly divisible by incr.

print_bytes_as_hex

Does what is says it's gonna.

print_simple
print_slice

[UNSTABLE]: MAY BE REMOVED AT ANY TIME Prints a vector to stdout. Used for debugging.

print_val_range
vec_remove_rebuild

Batch removes elements from a vector using a list of indices to remove.