Refactoring and report null chunks

The spec is not exactly clear on what should happen when a null chunk
name is encountered.
Add an error about invalid PC and more refactoring

The current failing tests trigger this warning and seem to have invalid
program counters.