LLVM Bugzilla is read-only and represents the historical archive of all LLVM issues filled before November 26, 2021. Use github to submit LLVM bugs

Bug 50429 - missing space between * and a variable
Summary: missing space between * and a variable
Status: RESOLVED FIXED
Alias: None
Product: clang
Classification: Unclassified
Component: Formatter (show other bugs)
Version: trunk
Hardware: PC Windows NT
: P enhancement
Assignee: Yilong Guo
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-05-21 00:46 PDT by liyang huang
Modified: 2021-06-08 17:48 PDT (History)
4 users (show)

See Also:
Fixed By Commit(s): rG21c18d5a04316891110cecc2bf37ce51533decba


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description liyang huang 2021-05-21 00:46:56 PDT
It seems that the `*` at the end was formatted with no space after it.

------------------------------------------
std::pair<int, int> crt2(int a, int m1, int b, int m2) {
  return std::make_pair(int(ll(b + m2 - a % m2) % m2 * inv_mod(m1, m2) % m2 * m1 + a), m1 *m2);
}
------------------------------------------

With the following settings:

------------------------------------------
BasedOnStyle: LLVM
Standard: Cpp11
PointerAlignment: Right
UseTab: Never
IndentWidth: 2
AccessModifierOffset: -2
AllowShortIfStatementsOnASingleLine: true
AlwaysBreakTemplateDeclarations: false
AllowShortLoopsOnASingleLine: true
ColumnLimit: 100
------------------------------------------
Comment 1 Yilong Guo 2021-06-02 22:13:11 PDT
Draft patch here: https://reviews.llvm.org/D103589