Refactor metavar formatting.