[llvm-bugs] [Bug 46241] New: Allow to set the space between function name and braces in calls, but avoid in definitions

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Jun 8 02:37:10 PDT 2020


https://bugs.llvm.org/show_bug.cgi?id=46241

            Bug ID: 46241
           Summary: Allow to set the space between function name and
                    braces in calls, but avoid in definitions
           Product: clang
           Version: 10.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Formatter
          Assignee: unassignedclangbugs at nondot.org
          Reporter: anton.kochkov at gmail.com
                CC: djasper at google.com, klimek at google.com,
                    llvm-bugs at lists.llvm.org

In radare2 project we use the following style:

int some_function(char *arg) {
     return strdup (arg);
}

int main(int argc, char** argv) {
     printf("foo: %s\n", some_function ("bar"));
     return 0; 
}

The key idea is to clearly differentiate declaration from calls. It is useful
for quick grepping with `git grep` or a plain `grep`. Please provide an option
to configure this.

https://github.com/radareorg/radare2/blob/master/DEVELOPERS.md

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200608/75c222e1/attachment.html>


More information about the llvm-bugs mailing list