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

            Bug ID: 31664
           Summary: Strange formatting for continuation with
                    AlignConsecutiveAssignments without assignment
           Product: clang
           Version: trunk
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Formatter
          Assignee: unassignedclangb...@nondot.org
          Reporter: roland.sch...@intel.com
                CC: djas...@google.com, kli...@google.com,
                    llvm-bugs@lists.llvm.org
    Classification: Unclassified

With config:
AlignConsecutiveDeclarations: true

Input:
gmx_bool     bGStatEveryStep, bGStat, bCalcVir, bCalcEnerStep, bCalcEner;
gmx_bool     bNS, bNStList, bSimAnn, bStopCM, bRerunMD, bFirstStep,
  startingFromCheckpoint, bInitStep, bLastStep=FALSE, bBornRadii,
  bUsingEnsembleRestraints;

Produces:
gmx_bool bGStatEveryStep, bGStat, bCalcVir, bCalcEnerStep, bCalcEner;
gmx_bool bNS, bNStList, bSimAnn, bStopCM, bRerunMD, bFirstStep,
    startingFromCheckpoint, bInitStep, bLastStep = FALSE, bBornRadii,
                                       bUsingEnsembleRestraints;

It seems inconsistent that for continuation lines only declarations with
assignment are taken into account. Either continuation should always be aligned
to the first declaration or they should always use the ContinuationIndentWidth.
I would prefer the first option.

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

Reply via email to