Very preliminary and possibly nonfunctional implementation of buffers.