fn wrap_item<F>(w: &mut Buffer, item_name: &str, f: F) where
    F: FnOnce(&mut Buffer),