Cleaner error reporting logic for BitStream