//! Functions for serializing NBT data into bytes.
use crate::;
/// Serializes a named `NbtCompound` into a `Vec` of bytes.
/// This function is guaranteed never to fail nor to generate any invalid nbt data.
///
/// # Examples
/// ```
/// let raw = include_bytes!("../tests/data/level_uncompressed.dat");
/// let (name, compound) = nbt_rs::parse_nbt(raw).unwrap();
/// let serialized = nbt_rs::serialize_nbt(&name, &compound);
/// assert_eq!(serialized, raw);
/// ```