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

            Bug ID: 46157
           Summary: Wrong spacing of negative literals with use of
                    operator
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: Formatter
          Assignee: unassignedclangb...@nondot.org
          Reporter: thomas.preudho...@celest.fr
                CC: djas...@google.com, kli...@google.com,
                    llvm-bugs@lists.llvm.org

Created attachment 23561
  --> https://bugs.llvm.org/attachment.cgi?id=23561&action=edit
Testcase with negative literal and operator

clang-format introduces a space after the sign of a literal when an operator is
involved. See attachment for an example. After running clang-format, one gets:
"- 42" instead of "-42". Using a variable or another literal instead of an
operator does not trigger the bug, so it seems related to the use of an
operator. As a matter of fact using just "operator" will trigger the bug but
not using "operato".

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to