Move to binary search in code_formatter.format_code logic + improve function definition formatter