Skip to content

Commit

Permalink
Merge pull request #4886 from correaa/update_multi_231223
Browse files Browse the repository at this point in the history
Update multi 231223
  • Loading branch information
ye-luo committed Dec 26, 2023
2 parents 86f4220 + d92cb4d commit 498a87a
Show file tree
Hide file tree
Showing 230 changed files with 25,553 additions and 13,006 deletions.
14 changes: 0 additions & 14 deletions external_codes/boost_multi/multi/.cirrus.yml

This file was deleted.

230 changes: 230 additions & 0 deletions external_codes/boost_multi/multi/.clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,230 @@
---
Language: Cpp
# BasedOnStyle: Google
#AccessModifierOffset: -1
AlignAfterOpenBracket: BlockIndent # Align
AlignArrayOfStructures: Right
#AlignConsecutiveMacros: None
AlignConsecutiveAssignments: Consecutive # None
#AlignConsecutiveBitFields: None
AlignConsecutiveDeclarations: Consecutive
#AlignEscapedNewlines: Left
AlignOperands: AlignAfterOperator
AlignTrailingComments: false
#AllowAllArgumentsOnNextLine: true
#AllowAllParametersOfDeclarationOnNextLine: true
#AllowShortEnumsOnASingleLine: true
#AllowShortBlocksOnASingleLine: Never
AllowShortCaseLabelsOnASingleLine: true # false
#AllowShortFunctionsOnASingleLine: All
#AllowShortLambdasOnASingleLine: All
#AllowShortIfStatementsOnASingleLine: WithoutElse
#AllowShortLoopsOnASingleLine: true
#AlwaysBreakAfterDefinitionReturnType: None
#AlwaysBreakAfterReturnType: None
#AlwaysBreakBeforeMultilineStrings: true
AlwaysBreakTemplateDeclarations: No # Yes
#AttributeMacros:
# - __capability
#BinPackArguments: true
#BinPackParameters: true
#BraceWrapping:
# AfterCaseLabel: false
# AfterClass: false
# AfterControlStatement: Never
# AfterEnum: false
# AfterFunction: false
# AfterNamespace: false
# AfterObjCDeclaration: false
# AfterStruct: false
# AfterUnion: false
# AfterExternBlock: false
# BeforeCatch: false
# BeforeElse: false
# BeforeLambdaBody: false
# BeforeWhile: false
# IndentBraces: false
# SplitEmptyFunction: true
# SplitEmptyRecord: true
# SplitEmptyNamespace: true
#BreakBeforeBinaryOperators: None
#BreakBeforeConceptDeclarations: true
#BreakBeforeBraces: Attach
#BreakBeforeInheritanceComma: false
BreakInheritanceList: BeforeComma
#BreakBeforeTernaryOperators: true
#BreakConstructorInitializersBeforeComma: false
#BreakConstructorInitializers: BeforeColon
#BreakAfterJavaFieldAnnotations: false
#BreakStringLiterals: true
ColumnLimit: 0
#CommentPragmas: '^ IWYU pragma:'
QualifierAlignment: Right # Leave
#CompactNamespaces: false
ConstructorInitializerIndentWidth: 0
ContinuationIndentWidth: 99
#Cpp11BracedListStyle: true
#DeriveLineEnding: true
#DerivePointerAlignment: true
#DisableFormat: false
#EmptyLineAfterAccessModifier: Never
#EmptyLineBeforeAccessModifier: LogicalBlock
#ExperimentalAutoDetectBinPacking: false
#PackConstructorInitializers: NextLine
#BasedOnStyle: ''
#ConstructorInitializerAllOnOneLineOrOnePerLine: false
#AllowAllConstructorInitializersOnNextLine: true
FixNamespaceComments: true
#ForEachMacros:
# - foreach
# - Q_FOREACH
# - BOOST_FOREACH
#IfMacros:
# - KJ_IF_MAYBE
#IncludeBlocks: Regroup
#IncludeCategories:
# - Regex: '^<ext/.*\.h>'
# Priority: 2
# SortPriority: 0
# CaseSensitive: false
# - Regex: '^<.*\.h>'
# Priority: 1
# SortPriority: 0
# CaseSensitive: false
# - Regex: '^<.*'
# Priority: 2
# SortPriority: 0
# CaseSensitive: false
# - Regex: '.*'
# Priority: 3
# SortPriority: 0
# CaseSensitive: false
#IncludeIsMainRegex: '([-_](test|unittest))?$'
#IncludeIsMainSourceRegex: ''
#IndentAccessModifiers: true # false
AccessModifierOffset: -98 # 2
#IndentCaseLabels: true
#IndentCaseBlocks: false
#IndentGotoLabels: true
#IndentPPDirectives: None
#IndentExternBlock: AfterExternBlock
#IndentRequires: false
IndentWidth: 99
#IndentWrappedFunctionNames: false
#InsertTrailingCommas: None
#JavaScriptQuotes: Leave
#JavaScriptWrapImports: true
#KeepEmptyLinesAtTheStartOfBlocks: false
#LambdaBodyIndentation: Signature
#MacroBlockBegin: ''
#MacroBlockEnd: ''
#MaxEmptyLinesToKeep: 1
#NamespaceIndentation: None
#ObjCBinPackProtocolList: Never
#ObjCBlockIndentWidth: 2
#ObjCBreakBeforeNestedBlockParam: true
#ObjCSpaceAfterProperty: false
#ObjCSpaceBeforeProtocolList: true
#PenaltyBreakAssignment: 2
#PenaltyBreakBeforeFirstCallParameter: 1
#PenaltyBreakComment: 300
#PenaltyBreakFirstLessLess: 120
#PenaltyBreakOpenParenthesis: 0
#PenaltyBreakString: 1000
PenaltyBreakTemplateDeclaration: 10
#PenaltyExcessCharacter: 1000000
#PenaltyReturnTypeOnItsOwnLine: 200
#PenaltyIndentedWhitespace: 0
PointerAlignment: Left
#PPIndentWidth: -1
#RawStringFormats:
# - Language: Cpp
# Delimiters:
# - cc
# - CC
# - cpp
# - Cpp
# - CPP
# - 'c++'
# - 'C++'
# CanonicalDelimiter: ''
# BasedOnStyle: google
# - Language: TextProto
# Delimiters:
# - pb
# - PB
# - proto
# - PROTO
# EnclosingFunctions:
# - EqualsProto
# - EquivToProto
# - PARSE_PARTIAL_TEXT_PROTO
# - PARSE_TEST_PROTO
# - PARSE_TEXT_PROTO
# - ParseTextOrDie
# - ParseTextProtoOrDie
# - ParseTestProto
# - ParsePartialTestProto
# CanonicalDelimiter: pb
# BasedOnStyle: google
#ReferenceAlignment: Pointer
#ReflowComments: true
#RemoveBracesLLVM: false
#SeparateDefinitionBlocks: Leave
#ShortNamespaceLines: 1
#SortIncludes: CaseSensitive
#SortJavaStaticImport: Before
#SortUsingDeclarations: true
#SpaceAfterCStyleCast: false
#SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: false # true
#SpaceBeforeAssignmentOperators: true
#SpaceBeforeCaseColon: false
#SpaceBeforeCpp11BracedList: false
#SpaceBeforeCtorInitializerColon: true
#SpaceBeforeInheritanceColon: true
SpaceBeforeParens: Custom # ControlStatements
SpaceBeforeParensOptions:
AfterControlStatements: false # true
# AfterForeachMacros: true
# AfterFunctionDefinitionName: false
# AfterFunctionDeclarationName: false
# AfterIfMacros: true
# AfterOverloadedOperator: false
# BeforeNonEmptyParentheses: false
#SpaceAroundPointerQualifiers: Default
#SpaceBeforeRangeBasedForLoopColon: true
#SpaceInEmptyBlock: false
#SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 2
#SpacesInAngles: Never
#SpacesInConditionalStatement: false
#SpacesInContainerLiterals: true
#SpacesInCStyleCastParentheses: false
SpacesInLineCommentPrefix:
Minimum: 1
# Maximum: -1
#SpacesInParentheses: false
#SpacesInSquareBrackets: false
#SpaceBeforeSquareBrackets: false
#BitFieldColonSpacing: Both
Standard: c++17
#StatementAttributeLikeMacros:
# - Q_EMIT
#StatementMacros:
# - Q_UNUSED
# - QT_REQUIRE_VERSION
TabWidth: 99
#UseCRLF: false
UseTab: ForContinuationAndIndentation # Never
WhitespaceSensitiveMacros:
- BOOST_REQUIRE
- BOOST_TEST
- BOOST_TEST_REQUIRE
#WhitespaceSensitiveMacros:
# - STRINGIZE
# - PP_STRINGIZE
# - BOOST_PP_STRINGIZE
# - NS_SWIFT_NAME
# - CF_SWIFT_NAME
...
54 changes: 16 additions & 38 deletions external_codes/boost_multi/multi/.clang-tidy
Original file line number Diff line number Diff line change
Expand Up @@ -5,67 +5,45 @@ HeaderFilterRegex: '.'
FormatStyle: file

CheckOptions:
- { key: readability-identifier-naming.ClassCase , value: lower_case }
- { key: readability-identifier-naming.ClassCase , value: lower_case }
- { key: readability-identifier-naming.FunctionCase , value: lower_case }
- { key: readability-identifier-naming.GlobalConstantCase , value: aNy_CasE }
- { key: readability-identifier-naming.NamespaceCase , value: lower_case }
- { key: readability-identifier-naming.PrivateMemberPrefix , value: '' }
- { key: readability-identifier-naming.PrivateMemberSufix , value: _ }
- { key: readability-identifier-naming.StructCase , value: lower_case }
- { key: readability-identifier-naming.TemplateParameterCase , value: CamelCase }
- { key: readability-identifier-length.MinimumVariableNameLength , value: 2 }
- { key: readability-identifier-length.MinimumParameterNameLength , value: 2 }
- { key: readability-identifier-length.MinimumLoopCounterNameLength, value: 2 }
- { key: readability-identifier-length.MinimumParameterNameLength , value: 2 }
- { key: readability-identifier-length.MinimumVariableNameLength , value: 2 }
- { key: readability-identifier-length.IgnoredLoopCounterNames , value: "^[ijk_]$" }
- { key: readability-identifier-length.IgnoredVariableNames , value: "^[ijk]$" }
- { key: readability-identifier-naming.GlobalConstantCase , value: aNy_CasE }
- { key: readability-identifier-naming.PrivateMemberSufix , value: _ }
- { key: readability-identifier-naming.TypeTemplateParameterIgnoredRegexp, value: expr-type}
# value: expr-type , bug in clang 16 in c++20 mode https://stackoverflow.com/a/75157215/225186

# - { key: readability-identifier-naming.VariableCase, value: aNy_CasE } for tests
# - { key: readability-identifier-naming.PrivateMethodSuffix, value: }
# for range-for loops, e.g. `for(auto i : is) ...`
# - { key: readability-identifier-length.IgnoredVariableNames , value: "^[ijk]$" }

Checks: '*,
-altera-id-dependent-backward-branch,
-altera-struct-pack-align,
-altera-unroll-loops,
-cert-err58-cpp,
-clang-diagnostic-c++98-compat-unnamed-type-template-args,
-cppcoreguidelines-avoid-magic-numbers,
-cppcoreguidelines-avoid-non-const-global-variables,
-cppcoreguidelines-macro-usage,
-cppcoreguidelines-pro-bounds-array-to-pointer-decay,
-cppcoreguidelines-pro-type-vararg,
-fuchsia-default-arguments-calls,
-fuchsia-default-arguments-declarations,
-fuchsia-overloaded-operator,
-fuchsia-statically-constructed-objects,
-fuchsia-trailing-return,
-hicpp-no-array-decay,
-hicpp-vararg,
-llvmlibc-callee-namespace,
-llvmlibc-implementation-in-namespace,
-llvmlibc-restrict-system-libc-headers,
-llvmlibc-*,
-modernize-use-nodiscard,
-readability-magic-numbers
'

# -altera-id-dependent-backward-branch, // seems like a buggy warning https://github.com/llvm/llvm-project/issues/52790
## explanation of the suppressed rules above:
# -altera-struct-pack-align, // this asks to use non-standard pragmas such as __attribute__((aligned(0))) and _attribute__((packed)), may interfeere with gcc/nvcc compatibility?
# -altera-unroll-loops, // expansion BOOST_REQUIRE macro requires this
# -cert-err58-cpp, // expansion BOOST_AUTO_TEST_CASE macro requires this
# -clang-diagnostic-c++98-compat-unnamed-type-template-args // allow lambda types in template parameters
# -cppcoreguidelines-avoid-magic-numbers, // all tests use magic numbers
# -cppcoreguidelines-avoid-non-const-global-variables, // expansion BOOST_AUTO_TEST_CASE macros require this
# -cppcoreguidelines-macro-usage, // definition of BOOST_TEST_MODULE macro requires this
# -cppcoreguidelines-pro-bounds-array-to-pointer-decay, // assert macros need this
# -cppcoreguidelines-pro-type-vararg, // expansion of BOOST_REQUIRE macros require this
# -fuchsia-default-arguments-declarations // BOOST_AUTO_TEST_CASE_TEMPLATE
# -fuchsia-default-arguments-calls, // expansion of BOOST_REQUIRE macros require this
# -fuchsia-overloaded-operator, // this library overloads operators (==, >, +, &)
# -fuchsia-statically-constructed-objects, // expansion of BOOST_AUTO_TEST_CASE creates these
# -fuchsia-trailing-return, // to allow any '-> decltype(auto)'
# -hicpp-no-array-decay, // all assert macros require this
# -hicpp-vararg, // all expansions of BOOST_TEST_REQUIRE macros require this
# -llvmlibc-implementation-in-namespace, // nonsense warning
# -llvmlibc-callee-namespace, // nonsense warning
# -llvmlibc-restrict-system-libc-headers, // nonsense warning
# -cppcoreguidelines-macro-usage, // BLAS adaptors uses a lot of macros
# -fuchsia-overloaded-operator, // this library overloads operators (==, <, +, &)
# -fuchsia-trailing-return, // to allow any '-> decltype(auto)', contradicts modernize trailing
# -llvmlibc-*, // nonsense warnings, for llvm developers
# -modernize-use-nodiscard, // this would add [[nodiscard]] to almost all functions, adding a lot of noise
# -readability-magic-numbers, // all tests use magic numbers

0 comments on commit 498a87a

Please sign in to comment.