Parser generator for binary formats