Implement register parsing.