Rough example (TODO: check begin/end ordering)