Max Kellermann
fe3e1d31bf
util/IntrusiveHashSet: remove unused type alias "ListHookTraits"
2022-12-01 15:10:38 +01:00
Max Kellermann
65f1cafa43
util/IntrusiveHashSet: add method find_if()
2022-12-01 15:10:32 +01:00
Max Kellermann
e3ef0929f1
util/IntrusiveHashSet: add const
overloads
2022-12-01 15:10:20 +01:00
Max Kellermann
8860962e09
util/IntrusiveHashSet: make several methods const
2022-12-01 15:10:13 +01:00
Max Kellermann
f13b8f669d
util/IntrusiveList: simplify ToHook() overload with const_cast
2022-12-01 15:10:09 +01:00
Max Kellermann
fa58db798b
lib/fmt/RuntimeError: new library
...
Replacing FormatRuntimeError().
2022-11-29 14:10:34 +01:00
Max Kellermann
45b13fc2a6
util/OptionParser: move to cmdline/
...
This library will depend on libfmt, and libutil shouldn't depend on
any library.
2022-11-29 11:32:16 +01:00
Max Kellermann
40d0828ccd
util/StringBuffer: add non-const iterator
2022-11-28 23:10:01 +01:00
Max Kellermann
d0d095cbcd
util/IntrusiveHashSet: rename "slot" to "bucket"
2022-11-22 21:40:52 +01:00
Max Kellermann
3239fce5c1
util/IntrusiveHashSet: add remove_and_dispose_if()
2022-11-22 21:40:11 +01:00
Max Kellermann
200b770104
util/IntrusiveHashSet: add for_each()
2022-11-22 21:40:04 +01:00
Max Kellermann
3aa959eda7
util/IntrusiveHashSet: add erase_and_dispose()
2022-11-22 21:39:40 +01:00
Max Kellermann
72c047f4f0
util/IntrusiveHashSet: add hash_function(), key_eq()
2022-11-21 09:10:44 +01:00
Max Kellermann
7c4fca0ae1
util/SpanCast: add ToStringView() template
2022-11-15 00:36:28 +01:00
Max Kellermann
51769c40d8
util/IntrusiveSortedList: new class
2022-11-13 09:08:36 +01:00
Max Kellermann
85ab89a08b
util/IntrusiveHashSet: add missing typename
(to make clang happy)
2022-11-13 08:40:53 +01:00
Max Kellermann
c943e27d51
util/IntrusiveHashSet: new class
...
Incomplete draft implementation, just enough methods for current
needs.
2022-11-13 08:38:53 +01:00
Max Kellermann
fb5d77158a
util/IntrusiveList: add enum LinkMode
...
Compile-time code simplification.
2022-11-13 08:15:47 +01:00
Max Kellermann
f1dc1af85d
util/IntrusiveList: use const_cast to eliminate duplicate HookTraits functions
...
I hate const_cast, but what I hate more is duplicate code. Sigh.
2022-11-12 08:45:24 +01:00
Max Kellermann
7b3d870516
util/IntrusiveForwardList: remove unnecessary initializer from hook
2022-11-11 21:14:52 +01:00
Max Kellermann
970ccf043b
util/SortList: enable the std::predicate kludge for macOS as well
...
Sigh.
2022-11-11 19:30:58 +01:00
Max Kellermann
29143dec87
util/SortList: kludge for Android NDK compatibility
2022-11-11 19:17:13 +01:00
Max Kellermann
a448d04d46
util/SortList: library which sorts linked lists
2022-11-11 19:03:39 +01:00
Max Kellermann
60e640af5a
util/IntrusiveList: add single-item splice() overload
2022-11-11 18:29:50 +01:00
Max Kellermann
df15c418c7
util/IntrusiveList: fix swap() implementation if second list is empty
2022-11-11 18:29:50 +01:00
Max Kellermann
04ab8ae27b
util/IntrusiveList: add type aliases value_type, pointer, reference
2022-11-11 17:15:20 +01:00
Max Kellermann
b4a64af15e
util/IntrusiveList: constant_time_size is a template argument, not a variable
2022-11-11 17:15:16 +01:00
Max Kellermann
838c057231
util/IntrusiveList: use auto
...
Fixes typos in the const_iterator return types, and fixes returning
references to stack values.
2022-11-11 16:33:49 +01:00
Max Kellermann
af544bb16f
util/IntrusiveList: fix typos
2022-11-11 10:11:42 +01:00
Max Kellermann
84fd401d21
util/IntrusiveList: add method splice()
2022-11-11 10:05:20 +01:00
Max Kellermann
b5d224496f
util/IntrusiveList: iterators are bidirectional
2022-11-11 09:20:09 +01:00
Max Kellermann
78d8b5f73c
util/OptionalCounter: add operator+= and operator-=
2022-11-10 16:55:04 +01:00
Max Kellermann
5670d98c54
util/IntrusiveList: move code to IntrusiveListNode::Connect()
2022-11-10 16:52:34 +01:00
Max Kellermann
1786eef8e6
util/IntrusiveForwardList: new class
2022-11-10 12:07:59 +01:00
Max Kellermann
988f5d1b5d
util/StringSplit: add SplitWhile()
2022-11-09 19:23:19 +01:00
Max Kellermann
3ab3d5555e
util/StringSplit: reimplement without std::distance()
...
Avoid including <iterator>.
2022-11-09 19:23:10 +01:00
Max Kellermann
2e5d46c399
util/StringSplit: add constexpr
2022-11-09 19:23:05 +01:00
Max Kellermann
7600ad7cac
util/StringSplit: add Partition()
2022-11-09 19:22:54 +01:00
Max Kellermann
485ad583a0
util/CharUtil: add IsLowerAlphaNumericASCII()
2022-11-09 19:21:43 +01:00
Max Kellermann
a12b004fa4
util/StaticVector: new class
2022-08-09 12:44:02 +02:00
Max Kellermann
cc0def15c4
Copyright year 2022
2022-07-14 17:59:35 +02:00
Max Kellermann
cd241a93c1
util/DynamicFifoBuffer: pass std::span to Append()
2022-07-11 22:38:24 +02:00
Max Kellermann
bc56f8c2f0
util/ConstBuffer: remove obsolete library
...
Everything has been migrated to std::span.
2022-07-04 19:15:10 +02:00
Max Kellermann
e8667f99be
util/OptionParser: use std::span instead of ConstBuffer
2022-07-04 19:04:16 +02:00
Max Kellermann
d89136b09c
util/ConstBuffer: hard-code std::span support
2022-07-04 18:09:32 +02:00
Max Kellermann
d58c38943a
util/StringView: remove obsolete class
...
Everything has been migrated to std::string_view.
2022-07-04 15:04:31 +02:00
Max Kellermann
66704ec879
util/UriExtract: use std::string_view instead of StringView
2022-07-04 15:04:31 +02:00
Max Kellermann
422c1e9288
util/TemplateString: remove StringView support
2022-07-04 15:04:31 +02:00
Max Kellermann
f32d752ccb
util/NumberParser: use std::string_view
2022-07-01 11:29:11 +02:00
Max Kellermann
02fe857755
util/IterableSplitString: return std::string_view
2022-07-01 11:29:11 +02:00
Max Kellermann
ea3f044cd8
util/SplitString: use std::string_view
2022-07-01 11:29:11 +02:00
Max Kellermann
6d23ac67f9
util/UriQueryParser: use std::string_view
2022-07-01 11:29:10 +02:00
Max Kellermann
ca46b4d7a7
util/MimeType: use std::string_view
2022-07-01 11:29:10 +02:00
Max Kellermann
9976665cc7
util/UriRelative: use std::string_view internally
2022-07-01 10:56:29 +02:00
Max Kellermann
c5f037fa64
util/StringCompare: move code from StringView
2022-07-01 10:48:34 +02:00
Max Kellermann
5ec13c0b06
util/StringStrip: add libc++ compatibility kludge
2022-07-01 10:45:37 +02:00
Max Kellermann
b806b0a97f
util/StringStrip: add std::string_view overloads
2022-06-30 21:00:07 +02:00
Max Kellermann
10197a0041
util/IterableSplitString: use std::string_view internally
2022-06-30 20:54:42 +02:00
Max Kellermann
166885802a
util/StringSplit: move code from StringView.hxx
2022-06-30 20:40:41 +02:00
Max Kellermann
0173d3b313
util/IterableSplitString: use StringView::Split()
2022-06-30 20:37:58 +02:00
Max Kellermann
aadd32c973
util/IterableSplitString: add noexcept
2022-06-30 20:34:04 +02:00
Max Kellermann
81afb47cd0
util/ByteOrder: add class PackedBE64
2022-06-30 10:30:54 +02:00
Max Kellermann
bc3415ce8b
Copyright year 2022
2022-06-30 09:41:53 +02:00
Max Kellermann
5140eaa5e7
util/IntrusiveList: use std::is_base_of_v
2022-06-29 17:30:11 +02:00
Max Kellermann
8a68d085b4
util/IntrusiveList: add option "constant_time_size"
2022-06-29 17:28:39 +02:00
Max Kellermann
e437cc4faf
util/IntrusiveList: add size()
2022-06-29 17:28:35 +02:00
Max Kellermann
1fb858e2d7
util/IntrusiveList: add struct IntrusiveListMemberHookTraits
2022-06-29 17:28:16 +02:00
Max Kellermann
3945a3add9
util/MemberPointer: new library
2022-06-29 17:28:15 +02:00
Max Kellermann
5348a446a7
util/IntrusiveList: move various static functions to struct IntrusiveListBaseHook
2022-06-29 17:27:40 +02:00
Max Kellermann
e8e33d5fc4
util/IntrusiveList: add missing ToHook() calls
2022-06-29 17:27:37 +02:00
Max Kellermann
c28580745b
util/IntrusiveList: move struct HookDetection to top-level
2022-06-29 17:24:08 +02:00
Max Kellermann
e7b587d550
util/CopyConst: use std::add_const
2022-06-29 17:23:50 +02:00
Max Kellermann
5d34b9b5bb
util/SpanCast: move CopyConst to separate header
2022-06-29 17:23:44 +02:00
Max Kellermann
86be7938f1
util/SpanCast: swap the CopyConst template parameters
2022-06-29 17:23:41 +02:00
Max Kellermann
7ad5a5efec
util/OffsetPointer: use std::byte
2022-06-29 17:23:32 +02:00
Max Kellermann
64f2735e60
util/SpanCast: add ToStringView()
2022-06-29 17:23:14 +02:00
Max Kellermann
3a0a0facdf
util/SpanCast: suppress alignment warnings
2022-06-29 17:23:13 +02:00
Max Kellermann
4cb5c3782b
util/HexFormat: require std::span
2022-06-29 17:22:17 +02:00
Max Kellermann
0a8aca516a
util/StringBuffer: use data() instead of &front()
2022-06-07 10:11:05 +02:00
Max Kellermann
70808bde64
util/ForeignFifoBuffer: add MoveFrom() overload with std::span
2022-06-07 10:09:08 +02:00
Max Kellermann
93bf0fc547
util/ForeignFifoBuffer: use iterators
2022-06-07 10:08:58 +02:00
Max Kellermann
95e7f8b1c8
util/ForeignFifoBuffer: more constexpr
2022-06-07 10:08:58 +02:00
Max Kellermann
27e78c71e0
util/HexFormat: use std::span instead of ConstBuffer
2022-06-01 22:50:54 +02:00
Max Kellermann
db03db0dca
util/SpanCast: add FromBytesStrict()
2022-06-01 21:50:01 +02:00
Max Kellermann
bd96f6e572
util/SpanCast: add const support to FromBytesFloor()
2022-06-01 21:49:35 +02:00
Max Kellermann
04041f9583
util/Manual: use std::aligned_storage_t
...
By using std::launder(), we can re-enable -Wstrict-aliasing.
2022-05-31 16:44:07 +02:00
Max Kellermann
826d1b207e
util/Manual: add type aliases
2022-05-31 16:44:07 +02:00
Max Kellermann
f92bae887f
util/Manual: add noexcept
2022-05-31 16:44:07 +02:00
Max Kellermann
d256d3dabe
util/StringCompare: use std::string_view instead of StringView
2022-05-31 13:24:45 +02:00
Max Kellermann
f045cf43e4
output/snapcast/Client: work around clang 14 std::span cast bug
...
Closes https://github.com/MusicPlayerDaemon/MPD/issues/1538
2022-05-24 14:18:50 +02:00
Max Kellermann
97f78059a2
util/AllocatedArray: add missing type alias "value_type"
2022-05-23 22:15:20 +02:00
Max Kellermann
01b32d5ee0
util/WritableBuffer: remove unused library
2022-05-20 11:22:03 +02:00
Max Kellermann
b50173ae8b
util/CircularBuffer: use std::span
2022-05-20 11:15:45 +02:00
Max Kellermann
b37c031fd1
util/{HugeAllocator,SparseBuffer}: use std::span
2022-05-20 11:15:45 +02:00
Max Kellermann
7006b075c3
util/AllocatedArray: fix -Wunused-parameter
2022-05-20 09:48:49 +02:00
Max Kellermann
5fb97b81d1
util/AllocatedArray: migrate from {Const,Writable}Buffer to std::span
2022-05-19 20:52:48 +02:00
Max Kellermann
bb7be9a4cd
util/*FifoBuffer: migrate from WritableBuffer to std::span
2022-05-19 14:01:57 +02:00
Max Kellermann
957d3e51e0
util/{Const,Writable}Buffer: add std::span cast operators
2022-05-19 13:25:02 +02:00
Max Kellermann
6e1500c251
Merge branch 'v0.23.x'
2022-04-26 21:05:39 +02:00
Max Kellermann
f88fc0ca1a
util/ByteOrder: add class PackedBE32
2022-04-26 21:03:05 +02:00
Max Kellermann
7ed67d216b
util/HugeAllocator: add SetName()
2022-04-26 20:44:36 +02:00
Max Kellermann
a742e1fc71
util/PeakBuffer, ...: use [[gnu::]] attributes
2022-04-26 20:31:56 +02:00
Max Kellermann
7293b32025
util/HexFormat: faster implementation without snprintf()
2022-03-14 12:18:52 +01:00
Max Kellermann
047e169f3e
util/BindMethod: merge MakeBind{Method,Function}Wrapper(), they are identical now
2021-12-03 13:51:56 +01:00
Max Kellermann
687327c9e8
util/BindMethod: merge structs {Method,Function}SignatureHelper into one
2021-12-03 13:51:56 +01:00
Max Kellermann
26dc37bd76
util/BindMethod: merge structs {Method,Function}WrapperGenerator into one
2021-12-03 13:51:55 +01:00
Max Kellermann
c693e4aa64
util/BindMethod: remove unused struct MethodWithSignature
2021-12-03 13:51:55 +01:00
Max Kellermann
acab731fef
util/BindMethod: simplify MakeBindFunctionWrapper()
2021-12-03 13:51:55 +01:00
Max Kellermann
7e4ba3cb72
util/BindMethod: add MethodSignatureHelper::function_pointer
2021-12-03 13:51:55 +01:00
Max Kellermann
172c4d9c7d
util/BindMethod: remove unnecessary template arguments from BindMethodWrapperGenerator
2021-12-03 13:51:55 +01:00
Max Kellermann
bd5f6cbc7b
util/BindMethod: simplify more templates using "auto" template arguments
2021-12-03 13:51:55 +01:00
Max Kellermann
6fcd1c734b
util/BindMethod: eliminate struct BindMethodWrapperGenerator2
2021-12-03 13:51:55 +01:00
Max Kellermann
eca097dbfb
util/BindMethod: simplify more templates using "auto" template arguments
2021-12-03 13:51:55 +01:00
Max Kellermann
51ffafa011
util/BindMethod: use std::remove_reference_t
2021-12-03 13:51:25 +01:00
Max Kellermann
8dca602346
util/BindMethod: simplify BindMethod()
2021-12-03 13:51:18 +01:00
Max Kellermann
0ed24f3a05
util/IntrusiveList: disallow copying IntrusiveListHook
2021-12-03 13:50:05 +01:00
August2111
1ff8626716
MSVC util/StringAPI.hxx add usage of MSVC compiler
2021-11-26 17:30:17 +01:00
Max Kellermann
05f529fffd
util/StringStrip: use [[gnu::...]] attributes
2021-11-26 16:24:55 +01:00
Max Kellermann
6f83bdd6f3
Merge branch '1' of git://github.com/neheb/MPD
2021-11-23 10:39:07 +01:00
Rosen Penev
9bcd425a85
array conversions
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-11-23 01:38:10 -08:00
Rosen Penev
250011f016
return by braced init list
...
shorter
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-11-22 23:28:08 -08:00
Max Kellermann
eea2d35d3a
util/AllocatedString, ...: add missing include for std::exchange()
...
Fixes building with GCC 12.
2021-11-19 16:06:20 +01:00
Shen-Ta Hsieh
e783c2bd2c
util/LazyRandomEngine: use std::optional to avoid allocation
...
Signed-off-by: Shen-Ta Hsieh <ibmibmibm.tw@gmail.com>
2021-11-14 03:53:42 +08:00
Max Kellermann
f8cbba1850
util/Alloc: remove unused library
2021-10-13 14:48:16 +02:00
Max Kellermann
635ec3ce37
util/VarSize: use plain malloc()
2021-10-13 14:46:40 +02:00
Max Kellermann
f510564d9d
more [[gnu::...]] attributes
2021-10-13 12:07:05 +02:00
Max Kellermann
a15c1c71d5
util/WritableBuffer: add WritableBuffer<void>::{FromVoid,ToVoid}()
2021-10-13 11:05:33 +02:00
Max Kellermann
8d679e7e00
util/IntrusiveList: add IntrusiveList::swap()
2021-10-13 11:04:42 +02:00
Max Kellermann
2b30ac2351
util/IntrusiveList: add another missing ToNode() call
2021-10-13 11:04:21 +02:00
Max Kellermann
1c97793b49
util/IntrusiveList: do not use the deprecated class std::iterator
...
Deprecated in C++17. Since C++17, one is supposed to declare those 5
types manually.
2021-10-13 11:03:49 +02:00
Max Kellermann
f6035f2dda
util/UriRelative: use std::string_view
...
Eliminates lots of implicit std::string temporaries.
2021-10-07 14:49:53 +02:00
Max Kellermann
c34a1e29de
util/UriRelative: fix variable mixup
2021-10-07 14:44:41 +02:00
James D. Smith
49ed9dae34
util/UriUtil: New uri_squash_dot_segments.
2021-10-07 13:14:54 +02:00
Max Kellermann
b1175acb59
util/StringView: hard-code C++17
2021-08-27 12:01:31 +02:00
Max Kellermann
672278e5fd
util/StringView: use [[gnu::]] attributes
2021-08-27 11:59:37 +02:00
Max Kellermann
da155f8822
util/StringCompare: use [[gnu::]] attributes
2021-08-27 11:58:25 +02:00
Max Kellermann
4026ef63b6
util/StringAPI: use [[gnu::]] attributes
2021-08-27 11:57:56 +02:00
Max Kellermann
b282682ba5
use using
instead of typedef
2021-08-27 11:57:33 +02:00
Max Kellermann
ad00926e1b
util/AllocatedArray: add method release()
2021-08-27 11:24:50 +02:00
Rosen Penev
53ffcf455c
make several member functions const
...
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-08-26 13:15:52 -07:00
Max Kellermann
8a9d678bac
Merge branch 'v0.22.x'
2021-05-25 18:21:42 +02:00
Namkhai B
dbe12a6b90
util/RuntimeError: Disable format-security for gcc
...
Fixes building under GCC 11
2021-05-25 18:19:19 +02:00
Max Kellermann
96707c0426
release v0.22.7
...
-----BEGIN PGP SIGNATURE-----
iQJEBAABCgAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAmClOSYQHG1heEBtdXNp
Y3BkLm9yZwAKCRAjbopYxttFEkODD/49e950HLmZE8x3rmyeEEsgdvHkOVpPlKHo
+wsmSsi+N0sQKgEOffSYyL0MRWaQqzRMnl1EcEVErCfQl5f1mOw9+TL4f5ZEjVNw
CQFMy1awHtCfktgF5zq6NzXD3nor9mkjiP733x/kGcsxwfk/Y4radqUBKJ5Y4a2B
YSg35a/YTOfLCmb9WBquwAi22x7AkyBzyrY3ToCzynVuaNcT3gvLsAAMFzRUKpqD
QEoCtUxJ4CQayjWjtG/bBCs2TVSmJvovhM2xB4Jnm+MeZz+bKI0y+ALW2Wk0Agnd
qxDqyCEnvHi5pf8i9usl4/A63VDC7HHj9kDSLtPLGTijv+7Wvvr4kNpwm2DuJ4q1
1pOEgT480ryK1FPyO6XnYCk616NqjgMbplr6SQ1DuVpIddWdiGARoge/WiNvsbT9
pnEp0q9V3cQmuJ30LlskMJHAPyrE3KSrO1s+4P2zUeirwnMnOCPdq+gT+lRw4GNG
OqLFEDHaELgSaZxInCN8RCXdLMrpuvKm+FQQApU1KwbYPXIassR14yt6BPpjxqea
vkvFLtpwFWthNPLkujak5rDqAPvbHzAeOfaOiZelzd21nl/1omiMXSXRcJkEjONi
JC5VWJpi1PHMXocq6AcOQT/9XhIH4uDA+Xghn7CURBTB6WoB954TSmuVIjXTfgAv
XQYqRR+7Yw==
=Gtzo
-----END PGP SIGNATURE-----
Merge tag 'v0.22.7'
release v0.22.7
2021-05-19 18:43:19 +02:00
Max Kellermann
a169a05e41
win32, ...: avoid including windows.h
...
Include the most specific header documented by MSDN instead.
2021-05-19 17:25:32 +02:00
Max Kellermann
28e7be248f
util/RuntimeError: disable -Wformat-security as a kludge
2021-05-19 14:57:20 +02:00
John Regan
87fa6bca54
flac encoder: enable Ogg FLAC and Ogg chaining
...
refactors GenerateOggSerial into a generic GenerateSerial
utility, under the util lib.
libFLAC may be encoded without Ogg support. If Ogg support is disabled,
libFLAC will still export Ogg-related methods (like setting a serial
number), and throw a runtime error when initializing an Ogg stream.
GenerateOggSerial does not depend on libogg. Refactoring it into
a generic GenerateSerial prevents having to add build-time checks
for libogg within the FLAC encoder plugin.
2021-05-15 11:31:01 -04:00
Max Kellermann
0122dc8452
util/BindMethod: drop support for GCC older than 7
2021-04-20 20:01:08 +02:00
Max Kellermann
95ad1b0cc6
use [[gnu::pure]] instead of gcc_pure
...
This is semi-standard and doesn't require the util/Compiler.h header.
2021-04-06 14:09:21 +02:00
Max Kellermann
52f46b94e9
util/AllocatedString: add concatenating constructor
2021-04-06 14:06:16 +02:00
Max Kellermann
e07e0bc9c1
util/AllocatedArray: include cleanup
2021-04-06 14:05:29 +02:00
Max Kellermann
ca726a0110
util/StringBuffer: make capacity() static
...
This allows using it in constant expressions.
2021-04-06 13:46:07 +02:00
Max Kellermann
e01710cbd1
util/DereferenceIterator: simplify operator->()
...
This makes it compatible with containers storing std::unique_ptr.
2021-04-06 13:45:32 +02:00
Max Kellermann
c87a4a7d08
util/DereferenceIterator: fix static_cast in operator->()
2021-04-06 13:45:10 +02:00
Max Kellermann
dc9103befe
util/AllocatedString: remove Null(), IsNull()
2021-03-04 18:05:29 +01:00
Max Kellermann
67760f5283
util/AllocatedString: support casting a nulled instance to string_view
2021-03-04 18:05:29 +01:00
Max Kellermann
99405a4c93
util/AllocatedString: add operator=()
2021-03-04 18:05:26 +01:00
Max Kellermann
b833c5d2c7
util/AllocatedString: replace Clone() with copy constructor
2021-03-04 18:04:21 +01:00
Max Kellermann
bca5d79f88
util/AllocatedString: add const_pointer constructor
2021-03-04 18:04:17 +01:00
Max Kellermann
6e1c8edf09
util/AllocatedString: add string_view constructor
...
Replaces the static Duplicate() method.
2021-03-04 18:04:11 +01:00
Max Kellermann
32b7b2e2fa
util/AllocatedString: add default constructor
2021-03-04 18:04:06 +01:00
Max Kellermann
cfb7f8ab84
util/AllocatedString: rename to BasicAllocatedString
...
To make things simpler, AllocatedString is now a non-template class.
2021-03-04 18:03:56 +01:00
Max Kellermann
a6eb264770
util/IntrusiveList: add type alias "Hook"
...
By casting to SafeLinkIntrusiveListHook if appropriate, this fixes a
bug in the erase() method, where erase() calls
IntrusiveListHook::unlink() instead of
SafeLinkIntrusiveListHook::unlink().
2021-03-02 17:51:50 +01:00
Max Kellermann
0091c4e12b
util/Exception: add FindNested()
2021-03-02 17:13:29 +01:00
Max Kellermann
80172e17ac
util/Exception: remove redundant std::exception catch clause
...
The "std::nested_exception" catch block already covers this perfectly.
2021-03-02 17:13:21 +01:00
Max Kellermann
ec0c1f0d02
util/Exception: fix comment typo
2021-03-02 17:12:20 +01:00
Max Kellermann
946b3c1f80
util/IntrusiveList: add method erase_and_dispose()
2021-02-25 14:12:47 +01:00
Max Kellermann
a0dc398f36
util/IntrusiveList: erase() returns an iterator
2021-02-25 14:12:39 +01:00
Max Kellermann
b54d2d984a
util/IntrusiveList: use ToHook() in erase()
2021-02-25 14:12:10 +01:00
Max Kellermann
4ab73f9de9
util/IntrusiveList: add missing ToNode() cast in iterator_to()
2021-02-25 14:10:55 +01:00
Max Kellermann
1048f23680
util/IntrusiveList: add hook class SafeLinkIntrusiveListHook
...
Similar to boost::intrusive::safe_link.
2021-02-24 20:29:16 +01:00
Max Kellermann
8fe8f09027
util/IntrusiveList: add noexcept
2021-02-24 20:17:28 +01:00
Max Kellermann
78670c0941
util/IntrusiveList: add constexpr
2021-02-24 20:16:54 +01:00
Max Kellermann
75e8795e3f
util/IntrusiveList: add method insert()
2021-02-22 23:32:51 +01:00
Max Kellermann
4912466d50
util/IntrusiveList: add method erase()
2021-02-22 23:32:47 +01:00
Max Kellermann
75c8d2235b
util/ByteOrder: add classes PackedBE16, PackedLE16, PackedLE32
2021-02-16 17:37:25 +01:00
Max Kellermann
3456b1e50d
use std::size_t
2021-02-12 18:39:28 +01:00
Max Kellermann
7fe0095fa7
util/IntrusiveList: add noexcept
to defaulted constructor
2021-02-11 21:22:15 +01:00
Max Kellermann
f4a5d671fe
util/{Const,Writable}Buffer: include cleanup
2021-02-04 17:27:48 +01:00
Max Kellermann
04731fb7cc
util/StringPointer: add operator==(std::nullptr_t)
2021-01-21 21:08:52 +01:00
Max Kellermann
9b2eb74f95
util/AllocatedString: fix operator= parameter type
2021-01-21 20:44:07 +01:00
Max Kellermann
84084baa65
util/AllocatedString: remove wrong std::
prefix
2021-01-21 20:16:32 +01:00
Max Kellermann
3bc45fbf68
util/AllocatedString: remove Null(), IsNull()
2021-01-21 20:12:05 +01:00
Max Kellermann
36168a24f5
util/AllocatedString: support casting a nulled instance to string_view
2021-01-21 20:06:01 +01:00
Max Kellermann
5e67443a1a
util/{Const,Writable}Buffer: always enable assertions
2021-01-21 20:04:00 +01:00
Max Kellermann
17858143b3
util/{Const,Writable}Buffer: enable constexpr
on more methods
2021-01-21 20:03:53 +01:00
Max Kellermann
c44a7b2705
util/AllocatedArray: add operator=(nullptr)
2021-01-21 20:03:38 +01:00
Max Kellermann
0ded23591b
util/AllocatedString: add operator=()
2021-01-21 20:02:52 +01:00
Max Kellermann
c1a7aa652d
util/AllocatedString: replace Clone() with copy constructor
2021-01-21 20:02:41 +01:00
Max Kellermann
8d47f51399
util/AllocatedString: add const_pointer constructor
2021-01-21 18:06:10 +01:00
Max Kellermann
a81c9bfb81
util/AllocatedString: add string_view constructor
...
Replaces the static Duplicate() method.
2021-01-21 18:05:51 +01:00
Max Kellermann
1caf57644f
util/AllocatedString: add default constructor
2021-01-21 18:05:50 +01:00
Max Kellermann
c70b63c183
util/AllocatedString: rename to BasicAllocatedString
...
To make things simpler, AllocatedString is now a non-template class.
2021-01-21 18:04:03 +01:00
Max Kellermann
8279cafd6d
release v0.22.4
...
-----BEGIN PGP SIGNATURE-----
iQJEBAABCgAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAmAJqgAQHG1heEBtdXNp
Y3BkLm9yZwAKCRAjbopYxttFEg2QEACJLeN2mk2RU7Iqxbh/ekwm6aTM8D6bx8RH
Xys4l1YAFQ0cg7sKZwMqefedGJG2j8CORbihYIF6Z8EvFsAiI6I3LjElfXrmnAc0
Y9SnWHIR5vxlSQgyqPlJ0jl213uzoHHpel8PpEJbTtYONT+8f3fQEuLpO4/uWOIT
S6mlX16vI0/Ydp//8UIazUUvjar1pPvBnSEZ0JZsZl8RTYlS/4SOfqpHnhhWnWpO
9RXlLP9Zo68rJzNhUPwRj7NkyVEkg74xpjHOWoyeTMNQ6tKMQn8b4jb/LcBfj6hk
I7mof5oX0aS+GyYaehKi9c9Az7wUcBxnnaN02qlAaSutcuox7ce70fKMtiAXRN0o
T9mFSJm1JKqHZb1dFvxqSqFjVr7eO9XCxHqaEqTbXCT+CL/6AJQZi5SVcX4gCY1P
NSM3Jnydjr73WFLmEfjCkWLTdtiJhY/2Q/J6+vcILMb3W2y5FaSHZTOFbxVG4nMM
spoQ27b7PoB9MbxLR3QJkYLa0WE3FrTORYgsH8Po7ZcCU9+JvqDSBnGXxx+Yv+JJ
dKMI5bEAvPziodSHHQXgD4lhx744JuiLAJNtlSYJvev1s2Irf2TtMHdmGERHQZwH
5cr9sQLgyHCLvTBDGt1dVZq/Z0T/PCkweIa5cT6ZBAim1hs7g20g8ksyFK2ZPUbB
vEGBNcuMIg==
=CEEr
-----END PGP SIGNATURE-----
Merge tag 'v0.22.4'
release v0.22.4
2021-01-21 17:42:26 +01:00
Max Kellermann
056ab199ab
util/PeakBuffer: add method max_size()
2021-01-21 16:45:56 +01:00
Max Kellermann
eea0e084af
util/PeakBuffer: use std::byte instead of std::uint8_t
2021-01-21 16:45:31 +01:00
Max Kellermann
fa82f558be
util/PeakBuffer: add noexcept
2021-01-21 16:45:17 +01:00
Max Kellermann
6b555b7017
util/PeakBuffer: use std::size_t
2021-01-21 16:45:14 +01:00
Max Kellermann
dafba203e7
util/ForeignFifoBuffer: use auto
2021-01-21 16:38:32 +01:00
Max Kellermann
07d2bc6898
util/StringView: add method SplitLast()
2021-01-21 13:20:01 +01:00
Max Kellermann
81ea749248
Merge branch 'v0.22.x'
2021-01-05 13:11:29 +01:00