Handle nested items.

* Use a stack to keep track of the current context. When a nested item needs to be parsed, push the current context onto the stack. When the nested item completes parsing, add the item's context to the parent. Pop.

fixes #26