llvm / llvm/llvm-project

Option for clang-format to remove empty lines in wrapped function call lines

Open
#178,219 1 comment 1 reaction 0 assignees View on GitHub
clang-format
Dominant language
LLVM
Stars
40.5k
Forks
18.7k
PR merge metrics
PR metrics pending

Description

If I have a function call like the following:
```
ALongFuctionNameToBeCalledHere(some_parameter_one_here,

another_long_name_here_so_wrapping_occurs);
```

I'd like the empty line to be removed by clang-format. `RemoveEmptyLinesInUnwrappedLines` seems close to what I'm looking for, but presumably doesn't have an effect because this is not an unwrapped line IIUC.

Contributor guide

Open the contributing guide

Research direction

Start by tracing clang-format's handling of RemoveEmptyLinesInUnwrappedLines and compare it with the wrapped function-call example in the issue. Done means providing an option that removes the empty line in that wrapped call without changing other formatting behavior; the issue names no file or test path, so those must be located first.

Written by the indexing model from the issue text.

Assessment

Domain
tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.