Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: SolidWallOfCode/libswoc
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 1.5.2
Choose a base ref
...
head repository: SolidWallOfCode/libswoc
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref

Commits on Jul 13, 2023

  1. Update to 1.5.3.

    SolidWallOfCode committed Jul 13, 2023
    Copy the full SHA
    9a5ad3c View commit details
  2. Copy the full SHA
    cc6ff1e View commit details

Commits on Jul 14, 2023

  1. Copy the full SHA
    b0e690d View commit details

Commits on Jul 19, 2023

  1. Copy the full SHA
    d90e66c View commit details
  2. Copy the full SHA
    49d040d View commit details

Commits on Jul 20, 2023

  1. Copy the full SHA
    f701827 View commit details
  2. Copy the full SHA
    9872326 View commit details
  3. Copy the full SHA
    81b8243 View commit details

Commits on Jul 25, 2023

  1. Copy the full SHA
    734be78 View commit details
  2. Copy the full SHA
    23eb3fc View commit details
  3. Copy the full SHA
    9e06070 View commit details
  4. Update to 1.5.4

    SolidWallOfCode committed Jul 25, 2023
    Copy the full SHA
    daacfac View commit details

Commits on Jul 31, 2023

  1. Copy the full SHA
    1229630 View commit details

Commits on Aug 6, 2023

  1. Copy the full SHA
    af04a67 View commit details

Commits on Aug 7, 2023

  1. Copy the full SHA
    d5ab329 View commit details
  2. Updatge to 1.5.5

    SolidWallOfCode committed Aug 7, 2023
    Copy the full SHA
    397b932 View commit details

Commits on Aug 14, 2023

  1. Copy the full SHA
    ca5af9f View commit details
  2. Copy the full SHA
    4eb6159 View commit details

Commits on Sep 10, 2023

  1. IPEndpoint: make ::port robust for invalid addresses

    We had a bwprint function throw the following for printing an adddress:
      "what():  sockaddr is not a valid IP address"
    
    This makes the ::port logic handle invalid (likely AF_UNSPEC) addresses.
    bneradt authored and SolidWallOfCode committed Sep 10, 2023
    Copy the full SHA
    6771a64 View commit details
  2. Copy the full SHA
    f92efb0 View commit details

Commits on Sep 19, 2023

  1. Copy the full SHA
    572542d View commit details
  2. Copy the full SHA
    6def36a View commit details

Commits on Sep 22, 2023

  1. Copy the full SHA
    f0c6a34 View commit details
  2. Update to 1.5.6

    SolidWallOfCode committed Sep 22, 2023
    Copy the full SHA
    e81ba68 View commit details

Commits on Oct 20, 2023

  1. Copy the full SHA
    61055cb View commit details
  2. Copy the full SHA
    85e7761 View commit details

Commits on Nov 6, 2023

  1. Copy the full SHA
    a7eeeb8 View commit details

Commits on Nov 8, 2023

  1. Copy the full SHA
    e680dad View commit details
  2. Copy the full SHA
    03eb94e View commit details

Commits on Nov 9, 2023

  1. Copy the full SHA
    365f16a View commit details
  2. Run clang format.

    SolidWallOfCode committed Nov 9, 2023
    Copy the full SHA
    7eb4786 View commit details
  3. Fix comment typo.

    SolidWallOfCode committed Nov 9, 2023
    Copy the full SHA
    c2c13c9 View commit details

Commits on Nov 15, 2023

  1. Copy the full SHA
    a79bc66 View commit details
  2. Update to 1.5.7

    SolidWallOfCode committed Nov 15, 2023
    Copy the full SHA
    ca594a6 View commit details
  3. Copy the full SHA
    b9ec19d View commit details
  4. Copy the full SHA
    9416362 View commit details
  5. Clang format.

    SolidWallOfCode committed Nov 15, 2023
    Copy the full SHA
    0969972 View commit details
  6. Update to 1.5.8

    SolidWallOfCode committed Nov 15, 2023
    Copy the full SHA
    b6ef38f View commit details

Commits on Nov 20, 2023

  1. Doc: update.

    SolidWallOfCode committed Nov 20, 2023
    Copy the full SHA
    3f7c595 View commit details

Commits on Nov 26, 2023

  1. Copy the full SHA
    04f3d4d View commit details
  2. Clang format.

    SolidWallOfCode committed Nov 26, 2023
    Copy the full SHA
    1bd9a3f View commit details
  3. Copy the full SHA
    172f8f9 View commit details

Commits on Nov 27, 2023

  1. Errata: fix is_ok

    SolidWallOfCode committed Nov 27, 2023
    Copy the full SHA
    1c7af86 View commit details
  2. Copy the full SHA
    2734914 View commit details

Commits on Nov 28, 2023

  1. Clang format.

    SolidWallOfCode committed Nov 28, 2023
    Copy the full SHA
    7e4df6c View commit details
  2. Update to 1.5.9

    SolidWallOfCode committed Nov 28, 2023
    Copy the full SHA
    2f83439 View commit details

Commits on Dec 8, 2023

  1. Copy the full SHA
    142f2db View commit details
  2. Copy the full SHA
    a9d6d47 View commit details

Commits on Dec 9, 2023

  1. Copy the full SHA
    563597c View commit details

Commits on Dec 13, 2023

  1. Copy the full SHA
    5cb7e29 View commit details
Showing with 5,145 additions and 2,904 deletions.
  1. +124 −26 .clang-format
  2. +3 −0 .idea/misc.xml
  3. +3 −1 CMakeLists.txt
  4. +4 −3 code/CMakeLists.txt
  5. +46 −16 code/include/swoc/BufferWriter.h
  6. +43 −31 code/include/swoc/DiscreteRange.h
  7. +169 −65 code/include/swoc/Errata.h
  8. +89 −70 code/include/swoc/IPAddr.h
  9. +127 −50 code/include/swoc/IPEndpoint.h
  10. +373 −148 code/include/swoc/IPRange.h
  11. +372 −179 code/include/swoc/IPSrv.h
  12. +289 −1 code/include/swoc/IntrusiveDList.h
  13. +5 −4 code/include/swoc/IntrusiveHashMap.h
  14. +2 −3 code/include/swoc/Lexicon.h
  15. +118 −18 code/include/swoc/MemArena.h
  16. +327 −150 code/include/swoc/MemSpan.h
  17. +7 −3 code/include/swoc/Scalar.h
  18. +164 −74 code/include/swoc/TextView.h
  19. +163 −152 code/include/swoc/Vectray.h
  20. +66 −34 code/include/swoc/bwf_base.h
  21. +22 −3 code/include/swoc/bwf_ex.h
  22. +5 −5 code/include/swoc/bwf_fwd.h
  23. +19 −2 code/include/swoc/bwf_ip.h
  24. +9 −5 code/include/swoc/bwf_std.h
  25. +67 −11 code/include/swoc/swoc_file.h
  26. +148 −0 code/include/swoc/swoc_ip_util.h
  27. +69 −8 code/include/swoc/swoc_meta.h
  28. +2 −2 code/include/swoc/swoc_version.h
  29. +1 −1 code/libswoc.part
  30. +24 −32 code/src/Errata.cc
  31. +52 −13 code/src/MemArena.cc
  32. +3 −2 code/src/RBTree.cc
  33. +24 −17 code/src/TextView.cc
  34. +113 −166 code/src/bw_format.cc
  35. +23 −11 code/src/bw_ip_format.cc
  36. +68 −49 code/src/swoc_file.cc
  37. +59 −51 code/src/swoc_ip.cc
  38. +1 −1 doc/Doxyfile
  39. +2 −1 doc/code/Errata.en.rst
  40. +29 −6 doc/code/TextView.en.rst
  41. +33 −18 doc/code/ip_networking.en.rst
  42. +1 −1 doc/conf.py
  43. +10 −3 doc/index.rst
  44. +2 −2 example/CMakeLists.txt
  45. +13 −9 example/ex_diskstats.cc
  46. +55 −38 example/ex_flat_space.cc
  47. +6 −5 example/ex_host_file.cc
  48. +72 −35 example/ex_lru_cache.cc
  49. +14 −12 example/ex_netcompact.cc
  50. +78 −75 example/ex_netdb.cc
  51. +0 −82 tools/ats-drop.sh
  52. +49 −19 tools/clang-format.sh
  53. +44 −0 tools/clang-tidy.conf
  54. +3 −1 tools/coverity.sh
  55. +20 −39 unit_tests/ex_IntrusiveDList.cc
  56. +34 −43 unit_tests/ex_Lexicon.cc
  57. +9 −18 unit_tests/ex_MemArena.cc
  58. +30 −42 unit_tests/ex_TextView.cc
  59. +34 −40 unit_tests/ex_UnitParser.cc
  60. +39 −64 unit_tests/ex_bw_format.cc
  61. +143 −99 unit_tests/ex_ipspace_properties.cc
  62. +41 −46 unit_tests/test_BufferWriter.cc
  63. +85 −35 unit_tests/test_Errata.cc
  64. +148 −8 unit_tests/test_IntrusiveDList.cc
  65. +9 −18 unit_tests/test_IntrusiveHashMap.cc
  66. +94 −67 unit_tests/test_Lexicon.cc
  67. +97 −48 unit_tests/test_MemArena.cc
  68. +85 −30 unit_tests/test_MemSpan.cc
  69. +4 −8 unit_tests/test_Scalar.cc
  70. +69 −54 unit_tests/test_TextView.cc
  71. +9 −11 unit_tests/test_Vectray.cc
  72. +52 −20 unit_tests/test_bw_format.cc
  73. +470 −453 unit_tests/test_ip.cc
  74. +34 −20 unit_tests/test_meta.cc
  75. +4 −5 unit_tests/test_range.cc
  76. +20 −20 unit_tests/test_swoc_file.cc
  77. +1 −2 unit_tests/unit_test_main.cc
150 changes: 124 additions & 26 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -2,62 +2,99 @@
Language: Cpp
AccessModifierOffset: -2
AlignAfterOpenBracket: Align
AlignConsecutiveMacros: false
AlignConsecutiveAssignments: true
AlignConsecutiveDeclarations: false
AlignArrayOfStructures: Left
AlignConsecutiveAssignments:
Enabled: true
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: true
PadOperators: true
AlignConsecutiveBitFields:
Enabled: true
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
PadOperators: false
AlignConsecutiveDeclarations:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
PadOperators: true
AlignConsecutiveMacros:
Enabled: true
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
PadOperators: true
AlignConsecutiveShortCaseStatements:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCaseColons: false
AlignEscapedNewlines: Left
AlignOperands: true
AlignTrailingComments: true
AllowAllArgumentsOnNextLine: true
AllowAllConstructorInitializersOnNextLine: true
AlignOperands: Align
AlignTrailingComments:
Kind: Always
OverEmptyLines: 0
AllowAllArgumentsOnNextLine: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortBlocksOnASingleLine: Never
AllowShortCaseLabelsOnASingleLine: false
AllowShortEnumsOnASingleLine: true
AllowShortFunctionsOnASingleLine: Inline
AllowShortLambdasOnASingleLine: All
AllowShortIfStatementsOnASingleLine: Never
AllowShortLambdasOnASingleLine: All
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: All
AlwaysBreakAfterReturnType: AllDefinitions
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: MultiLine
AttributeMacros:
- __capability
BinPackArguments: true
BinPackParameters: true
BitFieldColonSpacing: Both
BraceWrapping:
AfterCaseLabel: false
AfterClass: true
AfterControlStatement: false
AfterControlStatement: Never
AfterEnum: false
AfterExternBlock: false
AfterFunction: true
AfterNamespace: true
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
BreakAfterAttributes: Never
BreakAfterJavaFieldAnnotations: false
BreakArrays: true
BreakBeforeBinaryOperators: None
BreakBeforeInheritanceComma: false
BreakInheritanceList: BeforeColon
BreakBeforeConceptDeclarations: Always
#BreakBeforeBraces: Linux
BreakBeforeInlineASMColon: OnlyMultiline
BreakBeforeTernaryOperators: false
BreakConstructorInitializersBeforeComma: false
BreakConstructorInitializers: BeforeColon
BreakAfterJavaFieldAnnotations: false
BreakInheritanceList: BeforeColon
BreakStringLiterals: true
ColumnLimit: 132
CommentPragmas: '^ IWYU pragma:'
CompactNamespaces: true
ConstructorInitializerAllOnOneLineOrOnePerLine: true
ConstructorInitializerIndentWidth: 2
ContinuationIndentWidth: 2
Cpp11BracedListStyle: true
DeriveLineEnding: true
DerivePointerAlignment: false
DisableFormat: false
EmptyLineAfterAccessModifier: Never
EmptyLineBeforeAccessModifier: LogicalBlock
ExperimentalAutoDetectBinPacking: false
FixNamespaceComments: true
ForEachMacros:
@@ -67,72 +104,133 @@ ForEachMacros:
- foreach
- Q_FOREACH
- BOOST_FOREACH
IfMacros:
- KJ_IF_MAYBE
IncludeBlocks: Preserve
IncludeCategories:
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
Priority: 2
SortPriority: 0
CaseSensitive: false
- Regex: '^(<|"(gtest|isl|json)/)'
Priority: 3
SortPriority: 0
CaseSensitive: false
- Regex: '.*'
Priority: 1
SortPriority: 0
CaseSensitive: false
IncludeIsMainRegex: '$'
IncludeIsMainSourceRegex: ''
IndentAccessModifiers: false
IndentCaseBlocks: false
IndentCaseLabels: false
IndentExternBlock: AfterExternBlock
IndentGotoLabels: true
IndentPPDirectives: None
IndentRequiresClause: true
IndentWidth: 2
IndentWrappedFunctionNames: false
InsertBraces: false
InsertNewlineAtEOF: true
InsertTrailingCommas: None
IntegerLiteralSeparator:
Binary: 0
BinaryMinDigits: 0
Decimal: 0
Hex: 0
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: false
KeepEmptyLinesAtEOF: false
LambdaBodyIndentation: Signature
LineEnding: DeriveLF
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 1
NamespaceIndentation: None
ObjCBinPackProtocolList: Auto
ObjCBlockIndentWidth: 2
ObjCBreakBeforeNestedBlockParam: true
ObjCSpaceAfterProperty: true
ObjCSpaceBeforeProtocolList: false
PackConstructorInitializers: NextLine
PenaltyBreakAssignment: 2
PenaltyBreakBeforeFirstCallParameter: 19
PenaltyBreakComment: 30000
PenaltyBreakFirstLessLess: 120
PenaltyBreakOpenParenthesis: 0
PenaltyBreakString: 1000
PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 1000000
PenaltyIndentedWhitespace: 0
PenaltyReturnTypeOnItsOwnLine: 200
PointerAlignment: Right
PPIndentWidth: -1
QualifierAlignment: Leave
ReferenceAlignment: Pointer
ReflowComments: true
SortIncludes: false
SortUsingDeclarations: false
RemoveBracesLLVM: false
RemoveParentheses: Leave
RemoveSemicolon: false
RequiresClausePosition: OwnLine
RequiresExpressionIndentation: OuterScope
SeparateDefinitionBlocks: Leave
ShortNamespaceLines: 1
SortIncludes: Never
SortJavaStaticImport: Before
SortUsingDeclarations: Never
SpaceAfterCStyleCast: false
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: true
SpaceAroundPointerQualifiers: Default
SpaceBeforeAssignmentOperators: true
SpaceBeforeCaseColon: false
SpaceBeforeCpp11BracedList: false
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
SpaceBeforeJsonColon: false
SpaceBeforeParens: ControlStatements
SpaceBeforeParensOptions:
AfterControlStatements: true
AfterForeachMacros: true
AfterFunctionDefinitionName: false
AfterFunctionDeclarationName: false
AfterIfMacros: true
AfterOverloadedOperator: false
AfterRequiresInClause: false
AfterRequiresInExpression: false
BeforeNonEmptyParentheses: false
SpaceBeforeRangeBasedForLoopColon: true
SpaceBeforeSquareBrackets: false
SpaceInEmptyBlock: false
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInConditionalStatement: false
SpacesInAngles: Never
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
SpacesInLineCommentPrefix:
Minimum: 1
Maximum: -1
SpacesInParens: Never
SpacesInParensOptions:
InCStyleCasts: false
InConditionalStatements: false
InEmptyParentheses: false
Other: false
SpacesInSquareBrackets: false
SpaceBeforeSquareBrackets: false
Standard: Latest
StatementAttributeLikeMacros:
- Q_EMIT
StatementMacros:
- Q_UNUSED
- QT_REQUIRE_VERSION
TabWidth: 8
UseCRLF: false
UseTab: Never
VerilogBreakBetweenInstancePorts: true
WhitespaceSensitiveMacros:
- STRINGIZE
- PP_STRINGIZE
- BOOST_PP_STRINGIZE
- NS_SWIFT_NAME
- CF_SWIFT_NAME
...

3 changes: 3 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -2,7 +2,9 @@ cmake_minimum_required(VERSION 3.14)

project("libSWOC")
include(CMakeDependentOption)
set(INSTALL_DIR ${CMAKE_HOME_DIRECTORY})
if (CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
set(CMAKE_INSTALL_PREFIX ${CMAKE_HOME_DIRECTORY}/image)
endif ()

cmake_dependent_option(LIBSWOC_TEST
"Enable generation of libswoc test targets" ON
7 changes: 4 additions & 3 deletions code/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 3.11)

project(Lib-SWOC CXX)
set(LIBSWOC_VERSION "1.5.2")
set(LIBSWOC_VERSION "1.5.10")
set(CMAKE_CXX_STANDARD 17)
cmake_policy(SET CMP0087 NEW)
# override "lib64" to be "lib" unless the user explicitly sets it.
@@ -25,6 +25,7 @@ set(HEADER_FILES
include/swoc/IntrusiveDList.h
include/swoc/IntrusiveHashMap.h
include/swoc/swoc_ip.h
include/swoc/swoc_ip_util.h
include/swoc/IPEndpoint.h
include/swoc/IPAddr.h
include/swoc/IPSrv.h
@@ -36,7 +37,7 @@ set(HEADER_FILES
include/swoc/TextView.h
include/swoc/swoc_file.h
include/swoc/swoc_meta.h
include/swoc/string_view.h
include/swoc/string_view_util.h
include/swoc/Vectray.h
)

@@ -58,7 +59,7 @@ set(CC_FILES
src/string_view_util.cc
)

add_library(libswoc SHARED ${CC_FILES})
add_library(libswoc SHARED ${CC_FILES} ${HEADER_FILES})
set_target_properties(libswoc PROPERTIES OUTPUT_NAME swoc-${LIBSWOC_VERSION})
if (CMAKE_COMPILER_IS_GNUCXX)
target_compile_options(libswoc PRIVATE -fPIC -Wall -Wextra -Werror -Wnon-virtual-dtor -Wpedantic -Wshadow)
Loading